From e626ecd2346b917d1b3397e0159bca4862214e9d Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Mon, 14 Jan 2013 23:29:50 -0800 Subject: Added test for untested nested annotation restriction. --- test/files/neg/nested-annotation.check | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 test/files/neg/nested-annotation.check (limited to 'test/files/neg/nested-annotation.check') diff --git a/test/files/neg/nested-annotation.check b/test/files/neg/nested-annotation.check new file mode 100644 index 0000000000..ca263943fe --- /dev/null +++ b/test/files/neg/nested-annotation.check @@ -0,0 +1,10 @@ +nested-annotation.scala:3: warning: Implementation restriction: subclassing Classfile does not +make your annotation visible at runtime. If that is what +you want, you must write the annotation class in Java. +class ComplexAnnotation(val value: Annotation) extends ClassfileAnnotation + ^ +nested-annotation.scala:8: error: nested classfile annotations must be defined in java; found: inline + @ComplexAnnotation(new inline) def bippy(): Int = 1 + ^ +one warning found +one error found -- cgit v1.2.3