Skip to content

Commit ca6b8f7

Browse files
committed
Make never an illegal source version
1 parent 3cff3be commit ca6b8f7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/config/SourceVersion.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ object SourceVersion extends Property.Key[SourceVersion]:
3434
def defaultSourceVersion = `3.6`
3535

3636
/** language versions that may appear in a language import, are deprecated, but not removed from the standard library. */
37-
val illegalSourceVersionNames = List("3.1-migration").map(_.toTermName)
37+
val illegalSourceVersionNames = List("3.1-migration", "never").map(_.toTermName)
3838

3939
/** language versions that the compiler recognises. */
4040
val validSourceVersionNames = values.toList.map(_.toString.toTermName)

0 commit comments

Comments
 (0)