File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed
compiler/src/dotty/tools/dotc Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -774,7 +774,7 @@ class TreeUnpickler(reader: TastyReader,
774774 def readRhs (implicit ctx : Context ): LazyTree =
775775 if (nothingButMods(end))
776776 EmptyTree
777- else if ( sym.isInlineMethod)
777+ else if sym.isInlineMethod && ! sym.is( Deferred ) then
778778 // The body of an inline method is stored in an annotation, so no need to unpickle it again
779779 new Trees .Lazy [Tree ] {
780780 def complete (implicit ctx : Context ) = typer.Inliner .bodyToInline(sym)
Original file line number Diff line number Diff line change @@ -2336,7 +2336,8 @@ class Typer extends Namer
23362336 val newCtx = if (ctx.owner.isTerm && adaptCreationContext(mdef)) ctx
23372337 else ctx.withNotNullInfos(initialNotNullInfos)
23382338 typed(mdef)(using newCtx) match {
2339- case mdef1 : DefDef if ! Inliner .bodyToInline(mdef1.symbol).isEmpty =>
2339+ case mdef1 : DefDef
2340+ if mdef1.symbol.is(Inline , butNot = Deferred ) && ! Inliner .bodyToInline(mdef1.symbol).isEmpty =>
23402341 buf ++= inlineExpansion(mdef1)
23412342 // replace body with expansion, because it will be used as inlined body
23422343 // from separately compiled files - the original BodyAnnotation is not kept.
You can’t perform that action at this time.
0 commit comments