Skip to content

Commit 8c7cd1b

Browse files
committed
Don't read contents when creating a source file
1 parent 0d6a5ef commit 8c7cd1b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/util/SourceFile.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ class SourceFile(val file: AbstractFile, computeContent: => Array[Char]) extends
6868

6969
def apply(idx: Int): Char = content().apply(idx)
7070

71-
val length: Int = content().length
71+
def length: Int = content().length
7272

7373
/** true for all source files except `NoSource` */
7474
def exists: Boolean = true

0 commit comments

Comments
 (0)