From 2d37cc0b846a0ba50eb534c2a7379efd95f72ebc Mon Sep 17 00:00:00 2001 From: Eugene Burmako Date: Mon, 21 Apr 2014 23:39:16 +0300 Subject: makes bundles friendly to -Ywarn-dead-code Apparently, the `new Bundle(???).impl` synthetic tree generated as a macro impl ref for bundles evokes -Ywarn-dead-code warnings. This pull requests changes `???` to `null` in order not to stress out the checker. What's in the argument doesn't actually make any difference anyway. --- test/files/pos/t8523.scala | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 test/files/pos/t8523.scala (limited to 'test/files/pos/t8523.scala') diff --git a/test/files/pos/t8523.scala b/test/files/pos/t8523.scala new file mode 100644 index 0000000000..dfcb35404d --- /dev/null +++ b/test/files/pos/t8523.scala @@ -0,0 +1,10 @@ +import scala.language.experimental.macros +import scala.reflect.macros.blackbox.Context + +class Impl(val c: Context) { + def impl: c.Tree = ??? +} + +object Macros { + def foo: Any = macro Impl.impl +} \ No newline at end of file -- cgit v1.2.3