langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java
changeset 42840 dfe1a03d4db4
parent 42827 36468b5fa7f4
child 43026 8e8b50c7491d
--- a/langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java	Mon Dec 19 11:15:01 2016 -0800
+++ b/langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java	Mon Dec 19 12:30:39 2016 -0800
@@ -386,13 +386,6 @@
             }
         },
 
-        // Another alternative to list modules in --add-modules option
-        new HiddenOption(true, "--include-system-modules") {
-            void process(JdepsTask task, String opt, String arg) throws BadArgs {
-                task.options.includeSystemModulePattern = Pattern.compile(arg);
-            }
-        },
-
         new Option(false, "-P", "-profile") {
             void process(JdepsTask task, String opt, String arg) throws BadArgs {
                 task.options.showProfile = true;
@@ -1021,8 +1014,8 @@
 
         // source filters
         builder.includePattern(options.includePattern);
-        builder.includeSystemModules(options.includeSystemModulePattern);
 
+        // target filters
         builder.filter(options.filterSamePackage, options.filterSameArchive);
         builder.findJDKInternals(options.findJDKInternals);
 
@@ -1044,11 +1037,6 @@
         if (options.filterRegex != null)
             builder.filter(options.filterRegex);
 
-        // check if system module is set
-        config.rootModules().stream()
-              .map(Module::name)
-              .forEach(builder::includeIfSystemModule);
-
         return builder.build();
     }
 
@@ -1162,7 +1150,6 @@
         Set<String> packageNames = new HashSet<>();
         Pattern regex;             // apply to the dependences
         Pattern includePattern;
-        Pattern includeSystemModulePattern;
         boolean inverse = false;
         boolean compileTimeView = false;
         String systemModulePath = System.getProperty("java.home");
@@ -1173,8 +1160,7 @@
         Runtime.Version multiRelease;
 
         boolean hasSourcePath() {
-            return !addmods.isEmpty() || includePattern != null ||
-                        includeSystemModulePattern != null;
+            return !addmods.isEmpty() || includePattern != null;
         }
 
         boolean hasFilter() {