langtools/src/jdk.compiler/share/classes/com/sun/tools/sjavac/Source.java
changeset 26275 d2ca1fed21a9
parent 26107 a4a156a33c94
child 31115 8d8e98052d5d
equal deleted inserted replaced
26274:02a5b23ee21c 26275:d2ca1fed21a9
   311             String fn = f.getPath().substring(rootPrefix);
   311             String fn = f.getPath().substring(rootPrefix);
   312             // Extract the package name.
   312             // Extract the package name.
   313             int sp = fn.lastIndexOf(File.separatorChar);
   313             int sp = fn.lastIndexOf(File.separatorChar);
   314             String pkg = "";
   314             String pkg = "";
   315             if (sp != -1) {
   315             if (sp != -1) {
   316                 pkg = fn.substring(0,sp).replace('/','.');
   316                 pkg = fn.substring(0,sp).replace(File.separatorChar,'.');
   317             }
   317             }
   318             // Is this a module-info.java file?
   318             // Is this a module-info.java file?
   319             if (fn.endsWith("module-info.java")) {
   319             if (fn.endsWith("module-info.java")) {
   320                 // Aha! We have recursed into a module!
   320                 // Aha! We have recursed into a module!
   321                 if (!currentModule.name().equals("")) {
   321                 if (!currentModule.name().equals("")) {