File tree Expand file tree Collapse file tree 4 files changed +7
-7
lines changed
compiler/src/dotty/tools/io Expand file tree Collapse file tree 4 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -67,7 +67,7 @@ class Directory(jpath: JPath) extends Path(jpath) {
67
67
* until it runs out of contents.
68
68
*/
69
69
def deepList (depth : Int = - 1 ): Iterator [Path ] =
70
- if (depth < 0 ) list ++ (dirs flatMap (_ deepList ( depth) ))
70
+ if (depth < 0 ) list ++ (dirs flatMap (_ deepList depth))
71
71
else if (depth == 0 ) Iterator .empty
72
72
else list ++ (dirs flatMap (_ deepList (depth - 1 )))
73
73
}
Original file line number Diff line number Diff line change @@ -125,9 +125,9 @@ object Streamable {
125
125
finally stream.close()
126
126
127
127
def bytes (is : => InputStream ): Array [Byte ] =
128
- ( new Bytes {
128
+ new Bytes {
129
129
def inputStream () = is
130
- }) .toByteArray()
130
+ }.toByteArray()
131
131
132
132
def slurp (is : => InputStream )(implicit codec : Codec ): String =
133
133
new Chars { def inputStream () = is } slurp codec
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ extends AbstractFile {
18
18
def path : String =
19
19
maybeContainer match {
20
20
case None => name
21
- case Some (parent) => parent.path+ '/' + name
21
+ case Some (parent) => parent.path + '/' + name
22
22
}
23
23
24
24
def absolute : AbstractFile = this
@@ -54,7 +54,7 @@ extends AbstractFile {
54
54
55
55
override def fileNamed (name : String ): AbstractFile =
56
56
Option (lookupName(name, directory = false )) getOrElse {
57
- val newFile = new VirtualFile (name, path+ '/' + name)
57
+ val newFile = new VirtualFile (name, path + '/' + name)
58
58
files(name) = newFile
59
59
newFile
60
60
}
Original file line number Diff line number Diff line change @@ -240,8 +240,8 @@ final class ManifestResources(val url: URL) extends ZipArchive(null) {
240
240
private def resourceInputStream (path : String ): InputStream = {
241
241
new FilterInputStream (null ) {
242
242
override def read (): Int = {
243
- if (in == null ) in = Thread .currentThread().getContextClassLoader().getResourceAsStream(path)
244
- if (in == null ) throw new RuntimeException (path + " not found" )
243
+ if (in == null ) in = Thread .currentThread().getContextClassLoader().getResourceAsStream(path)
244
+ if (in == null ) throw new RuntimeException (path + " not found" )
245
245
super .read()
246
246
}
247
247
You can’t perform that action at this time.
0 commit comments