New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ToolBox.eval cannot find macro implementation #6636
Comments
Imported From: https://issues.scala-lang.org/browse/SI-6636?orig=1 |
@xeno-by said: |
Tomer Gabel (holograph) said: |
@xeno-by said: |
@retronym said: Not sure if this represents a bug per se, or just a limitation one has to live with. |
@xeno-by said: protected def findMacroClassLoader(): ClassLoader = {
val classpath = global.classPath.asURLs
macroLogVerbose("macro classloader: initializing from -cp: %s".format(classpath))
ScalaClassLoader.fromURLs(classpath, self.getClass.getClassLoader)
} This logic is obviously incompatible with ReflectGlobal, which doesn't populate global.classPath correctly. |
@adriaanm said: |
Macro definition:
Macro use:
Compiling
test-macro.scala
yields the expected error message:However, using
eval
fails:The text was updated successfully, but these errors were encountered: