From d171b2cc16cc129e0f3aa03c3df9b2fb86208aa6 Mon Sep 17 00:00:00 2001 From: Miles Sabin Date: Wed, 10 Aug 2016 09:30:49 +0100 Subject: Partial fix for SI-7046 --- test/files/neg/t7046-2/Test_2.scala | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 test/files/neg/t7046-2/Test_2.scala (limited to 'test/files/neg/t7046-2/Test_2.scala') diff --git a/test/files/neg/t7046-2/Test_2.scala b/test/files/neg/t7046-2/Test_2.scala new file mode 100644 index 0000000000..18a2ebcbc2 --- /dev/null +++ b/test/files/neg/t7046-2/Test_2.scala @@ -0,0 +1,14 @@ +object Test extends App { + def nested: Unit = { + val subs = Macros.knownDirectSubclasses[Foo] + assert(subs == List("Bar", "Baz")) + + sealed trait Foo + object Foo { + trait Bar extends Foo + trait Baz extends Foo + } + } + + nested +} -- cgit v1.2.3