summaryrefslogtreecommitdiff
path: root/test/pending/run/macro-overload/Macros_1.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/pending/run/macro-overload/Macros_1.scala')
-rw-r--r--test/pending/run/macro-overload/Macros_1.scala9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/pending/run/macro-overload/Macros_1.scala b/test/pending/run/macro-overload/Macros_1.scala
new file mode 100644
index 0000000000..f24c69ea7b
--- /dev/null
+++ b/test/pending/run/macro-overload/Macros_1.scala
@@ -0,0 +1,9 @@
+object Macros {
+ def macro bar(x: Int): Int = Apply(Select(Select(Ident("scala"), newTermName("Predef")), newTermName("println")), List(Literal(Constant("object-Int"))))
+ def macro bar(x: String): String = Apply(Select(Select(Ident("scala"), newTermName("Predef")), newTermName("println")), List(Literal(Constant("object-String"))))
+}
+
+class Macros {
+ def macro bar(x: Int): Int = Apply(Select(Select(Ident("scala"), newTermName("Predef")), newTermName("println")), List(Literal(Constant("class-Int"))))
+ def macro bar(x: String): String = Apply(Select(Select(Ident("scala"), newTermName("Predef")), newTermName("println")), List(Literal(Constant("class-String"))))
+} \ No newline at end of file