diff --git a/tests/pos/i8143.scala b/tests/pos/i8143.scala new file mode 100644 index 000000000000..ac0f3b5b1d8f --- /dev/null +++ b/tests/pos/i8143.scala @@ -0,0 +1,11 @@ +class Reflection(val internal: CompilerInterface) { self => // It works if the self is removed + opaque type Flags = internal.Flags + object Flags { + def EmptyFlags: Flags = internal.Flags_EmptyFlags + } +} + +trait CompilerInterface { + type Flags + def Flags_EmptyFlags: Flags +}