Skip to content

Commit 0637c3b

Browse files
committed
Simplify decision about whether to emit ACC_ABSTRACT
Look at the RHS of the DefDef, rather than at flags of the Symbol
1 parent 36937e7 commit 0637c3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/compiler/scala/tools/nsc/backend/jvm/BCodeSkelBuilder.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,7 @@ abstract class BCodeSkelBuilder extends BCodeHelpers {
563563
}
564564

565565
val isNative = methSymbol.hasAnnotation(definitions.NativeAttr)
566-
val isAbstractMethod = (methSymbol.isDeferred || methSymbol.owner.isInterface) && !methSymbol.hasFlag(Flags.JAVA_DEFAULTMETHOD)
566+
val isAbstractMethod = rhs == EmptyTree
567567
val flags = GenBCode.mkFlags(
568568
javaFlags(methSymbol),
569569
if (isAbstractMethod) asm.Opcodes.ACC_ABSTRACT else 0,

0 commit comments

Comments
 (0)