Closed
Description
Compiler version
3.3.3, 3.4.0, c8c3bde (main)
Minimized code
Main.scala:
@main def main() =
Repro[JavaClass]
Macro.scala
import scala.quoted.*
object Repro {
inline def apply[A]: Unit = ${ applyImpl[A] }
def applyImpl[A](using Type[A], Quotes): Expr[Unit] = {
import quotes.*, quotes.reflect.*
println(TypeRepr.of[A].show + " " + TypeRepr.of[A].typeSymbol.primaryConstructor.flags.show)
'{ () }
}
}
JavaClass.java:
public class JavaClass {}
Output
JavaClass Flags.JavaDefined | Flags.Local | Flags.Method | Flags.Private | Flags.PrivateLocal
Expectation
The Flags.Private
and Flags.PrivateLocal
should not be a part of the flagset of a public constructor method
Related: scalalandio/chimney#484 (comment)