Skip to content

Commit 3d3021c

Browse files
liufengyunodersky
authored andcommitted
Add one more test
1 parent 4d14e7e commit 3d3021c

File tree

2 files changed

+18
-6
lines changed

2 files changed

+18
-6
lines changed

tests/pos-special/fatal-warnings/i7219.scala

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,6 @@ object Foo {
88

99
object Bar {
1010
type Blue = Foo.Blue
11-
12-
// Related Issue -- my expectation is that
13-
// `export Foo.Blue` should be equivalent to
14-
// `type Blue = Foo.Blue`, but it's not:
15-
16-
// export Foo.Blue // Uncommenting this (and commenting `type Blue = ...`) results in compile error
1711
}
1812

1913
import Foo._
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
object Foo {
2+
enum MyEnum {
3+
case Red
4+
case Blue(msg: String)
5+
}
6+
export MyEnum._
7+
}
8+
9+
object Bar {
10+
export Foo.Blue
11+
}
12+
13+
import Foo._
14+
15+
def foo(a: MyEnum): Seq[Bar.Blue] = a match {
16+
case Red => Seq.empty
17+
case m: Foo.Blue => Seq(m)
18+
}

0 commit comments

Comments
 (0)