Closed
Description
The following code should not compile.
scala> object Foo { val 1 = 2 }
defined module Foo
Also, as been pointed out by Seth Tisue, the defined val shadows the corresponding integer literal, producing unexpected behavior:
scala> object O { val 1 = 2; def x = 1 }
defined module O
scala> O.x
scala.MatchError: 2 (of class java.lang.Integer)