diff options
Diffstat (limited to 'tests/disabled/macro/run/t7047')
-rw-r--r-- | tests/disabled/macro/run/t7047/Impls_Macros_1.scala | 19 | ||||
-rw-r--r-- | tests/disabled/macro/run/t7047/Test_2.scala | 3 |
2 files changed, 22 insertions, 0 deletions
diff --git a/tests/disabled/macro/run/t7047/Impls_Macros_1.scala b/tests/disabled/macro/run/t7047/Impls_Macros_1.scala new file mode 100644 index 000000000..787ea6cfe --- /dev/null +++ b/tests/disabled/macro/run/t7047/Impls_Macros_1.scala @@ -0,0 +1,19 @@ +import scala.reflect.macros.blackbox.Context +import language.experimental.macros + +class Foo + +object Macros { + def impl(c: Context) = { + import c.universe._ + try { + c.inferImplicitValue(typeOf[Foo], silent = false) + c.abort(c.enclosingPosition, "silent=false is not working") + } catch { + case _: Exception => + } + c.Expr[Null](Literal(Constant(null))) + } + + def foo = macro impl +}
\ No newline at end of file diff --git a/tests/disabled/macro/run/t7047/Test_2.scala b/tests/disabled/macro/run/t7047/Test_2.scala new file mode 100644 index 000000000..0fc472aa6 --- /dev/null +++ b/tests/disabled/macro/run/t7047/Test_2.scala @@ -0,0 +1,3 @@ +object Test extends dotty.runtime.LegacyApp { + Macros.foo +}
\ No newline at end of file |