From 223fa2bea328fc53f87d6f9d0c28c67545e831af Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Thu, 18 Dec 2014 15:39:55 +0100 Subject: More careful usage of unforced decls in classes. 1) Rename `decls` to `unforcedDecls` to make it clear that it is danegrous to use. 2) Prefer `info.decls` over `unforcedDecls`. This fixes the problem reported in #305 where the primary constructor was not found. --- tests/pos/annot-bootstrap.scala | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 tests/pos/annot-bootstrap.scala (limited to 'tests/pos') diff --git a/tests/pos/annot-bootstrap.scala b/tests/pos/annot-bootstrap.scala new file mode 100644 index 000000000..bef877dcd --- /dev/null +++ b/tests/pos/annot-bootstrap.scala @@ -0,0 +1,8 @@ +package scala.annotation.unchecked + +// note: if the case class is not inside an object, the error disappears +object test { + case class L(a: Int) +} + +final class uncheckedVariance extends scala.annotation.StaticAnnotation {} -- cgit v1.2.3