We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c35b8f commit 5e47371Copy full SHA for 5e47371
compiler/src/dotty/tools/dotc/typer/Namer.scala
@@ -748,10 +748,10 @@ class Namer { typer: Typer =>
748
749
protected def addAnnotations(sym: Symbol): Unit = original match {
750
case original: untpd.MemberDef =>
751
- lazy val annotCtx = annotContext(original, sym)
+ def annotCtx(implicit ctx: Context) = annotContext(original, sym)
752
for (annotTree <- untpd.modsDeco(original).mods.annotations) {
753
val cls = typedAheadAnnotationClass(annotTree)(annotCtx)
754
- val ann = Annotation.deferred(cls, implicit ctx => typedAnnotation(annotTree))
+ val ann = Annotation.deferred(cls, implicit ctx => typedAnnotation(annotTree)(annotCtx))
755
sym.addAnnotation(ann)
756
if (cls == defn.ForceInlineAnnot && sym.is(Method, butNot = Accessor))
757
sym.setFlag(Inline)
0 commit comments