< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/file/Locations.java

Print this page

        

*** 1568,1593 **** int eq = v.indexOf('='); if (eq > 0) { String moduleName = v.substring(0, eq); SearchPath mPatchPath = new SearchPath() .addFiles(v.substring(eq + 1)); - boolean ok = true; - for (Path p : mPatchPath) { - Path mi = p.resolve("module-info.class"); - if (Files.exists(mi)) { - log.error(Errors.LocnModuleInfoNotAllowedOnPatchPath(mi)); - ok = false; - } - } - if (ok) { String name = location.getName() + "[" + moduleName + "]"; ModuleLocationHandler h = new ModuleLocationHandler(name, moduleName, mPatchPath, false); moduleLocations.put(moduleName, h); for (Path r : mPatchPath) { pathLocations.put(normalize(r), h); } - } } else { // Should not be able to get here; // this should be caught and handled in Option.PATCH_MODULE log.error(Errors.LocnInvalidArgForXpatch(value)); } --- 1568,1583 ----
< prev index next >