File tree 1 file changed +4
-2
lines changed
compiler/src/dotty/tools/io
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -10,11 +10,13 @@ import scala.jdk.CollectionConverters.*
10
10
* This class implements an [[AbstractFile ]] backed by a jar
11
11
* that be can used as the compiler's output directory.
12
12
*/
13
- class JarArchive private (root : Directory ) extends PlainDirectory (root) {
13
+ class JarArchive private (val jarPath : Path , root : Directory ) extends PlainDirectory (root) {
14
14
def close (): Unit = this .synchronized (jpath.getFileSystem().close())
15
15
override def exists : Boolean = jpath.getFileSystem().isOpen() && super .exists
16
16
def allFileNames (): Iterator [String ] =
17
17
java.nio.file.Files .walk(jpath).iterator().asScala.map(_.toString)
18
+
19
+ override def toString : String = jarPath.toString
18
20
}
19
21
20
22
object JarArchive {
@@ -40,6 +42,6 @@ object JarArchive {
40
42
}
41
43
}
42
44
val root = fs.getRootDirectories().iterator.next()
43
- new JarArchive (Directory (root))
45
+ new JarArchive (path, Directory (root))
44
46
}
45
47
}
You can’t perform that action at this time.
0 commit comments