Open
Description
Compiler version
3.6.3
Minimized code
my-macro.scala (if renamed to myMacro.scala
, works fine)
import scala.quoted.*
transparent inline def foo =
${ fooImpl }
def fooImpl(using Quotes): Expr[Any] =
Expr("hello")
test.scala
val x = foo
Output
% scalac my-macro.scala test.scala
Cyclic macro dependencies in test.scala.
Compilation stopped since no further progress can be made.
To fix this, place macros in one set of files and their callers in another.
Compile with -Xprint-suspension for information.
1 error found
Expectation
Should compile, just like when renamed to myMacro.scala
:
% cp my-macro.scala myMacro.scala
% scalac myMacro.scala test.scala
% echo $?
0