diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/files/run/t2111.check | 6 | ||||
-rw-r--r-- | test/files/run/t2111.scala | 20 |
2 files changed, 26 insertions, 0 deletions
diff --git a/test/files/run/t2111.check b/test/files/run/t2111.check new file mode 100644 index 0000000000..0fc64f38ed --- /dev/null +++ b/test/files/run/t2111.check @@ -0,0 +1,6 @@ +Red +Green +Blue +Blue +Green +Red diff --git a/test/files/run/t2111.scala b/test/files/run/t2111.scala new file mode 100644 index 0000000000..3c6c5b8e8f --- /dev/null +++ b/test/files/run/t2111.scala @@ -0,0 +1,20 @@ + +object Test extends Application { + + object Color extends Enumeration { + val Red, Green, Blue = Value + } + + class MyColor extends Enumeration { + val Red, Green, Blue = Value + } + + println(Color.Red) + println(Color.Green) + println(Color.Blue) + val col = new MyColor + println(col.Blue) + println(col.Green) + println(col.Red) + +} |