From 7b73731ca3ff11705abba82caf0cf4d71efe1816 Mon Sep 17 00:00:00 2001 From: Bartosz Popiela Date: Wed, 1 May 2024 16:12:04 +0200 Subject: [PATCH] fix "java.nio.file.InvalidPathException: Illegal char <:> at index 2" (#262) --- .../javaparser/generators/ClasspathParser.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/src/com/github/bazel_contrib/contrib_rules_jvm/javaparser/generators/ClasspathParser.java b/java/src/com/github/bazel_contrib/contrib_rules_jvm/javaparser/generators/ClasspathParser.java index 245d92b3..6b770573 100644 --- a/java/src/com/github/bazel_contrib/contrib_rules_jvm/javaparser/generators/ClasspathParser.java +++ b/java/src/com/github/bazel_contrib/contrib_rules_jvm/javaparser/generators/ClasspathParser.java @@ -180,7 +180,7 @@ class ClassScanner extends TreeScanner { @Override public Void visitCompilationUnit(CompilationUnitTree t, Void v) { compileUnit = t; - fileName = Paths.get(compileUnit.getSourceFile().toUri().getPath()).getFileName().toString(); + fileName = Paths.get(compileUnit.getSourceFile().toUri()).getFileName().toString(); currentClassName = null; currentFileImports = new HashMap<>();