summaryrefslogtreecommitdiff
path: root/test/files/run/macro-reify-type.flags
diff options
context:
space:
mode:
authorEugene Burmako <xeno.by@gmail.com>2012-09-23 14:07:22 +0200
committerEugene Burmako <xeno.by@gmail.com>2012-09-28 14:21:45 +0200
commita6b81ac12a45866e97d30133c12dee775b93ea39 (patch)
tree89020413a56a36ebde3a02b99e4ec367f81cf33c /test/files/run/macro-reify-type.flags
parent4e87654a9187fc65e5971580f4e25589fff052b9 (diff)
downloadscala-a6b81ac12a45866e97d30133c12dee775b93ea39.tar.gz
scala-a6b81ac12a45866e97d30133c12dee775b93ea39.tar.bz2
scala-a6b81ac12a45866e97d30133c12dee775b93ea39.zip
SI-6417 correctly reifies non-value types
If we're reifying non-value types (e.g. MethodTypes), we can't use them as type arguments for TypeTag/WeakTypeTag factory methods, otherwise the macro expansion won't typecheck: http://groups.google.com/group/scala-internals/browse_thread/thread/2d7bb85bfcdb2e2 This situation is impossible if one uses only reify and type tags, but c.reifyTree and c.reifyType exposes in the macro API let anyone feed anything into the reifier. Therefore I now check the tpe that is about to be used in TypeApply wrapping TypeTag/WeakTypeTag factory methods and replace it with AnyTpe if it doesn't fit.
Diffstat (limited to 'test/files/run/macro-reify-type.flags')
-rw-r--r--test/files/run/macro-reify-type.flags1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/files/run/macro-reify-type.flags b/test/files/run/macro-reify-type.flags
new file mode 100644
index 0000000000..cd66464f2f
--- /dev/null
+++ b/test/files/run/macro-reify-type.flags
@@ -0,0 +1 @@
+-language:experimental.macros \ No newline at end of file