Skip to content

Commit 6af879d

Browse files
committed
Fix java enum flag
Previously the flag is not set properly
1 parent af37d64 commit 6af879d

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

compiler/src/dotty/tools/dotc/core/classfile/ClassfileConstants.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -362,6 +362,7 @@ object ClassfileConstants {
362362
res = addFlag(res, nflags & JAVA_ACC_FINAL)
363363
res = addFlag(res, nflags & JAVA_ACC_SYNTHETIC)
364364
res = addFlag(res, nflags & JAVA_ACC_STATIC)
365+
res = addFlag(res, nflags & JAVA_ACC_ENUM)
365366
res = addFlag(res, nflags & JAVA_ACC_ABSTRACT)
366367
res = addFlag(res, nflags & JAVA_ACC_INTERFACE)
367368
res

compiler/src/dotty/tools/dotc/transform/TypeTestsCasts.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,9 @@ object TypeTestsCasts {
120120
maximizeType(P1, span, fromScala2x = false)
121121

122122
val res = P1 <:< P
123+
124+
debug.println(TypeComparer.explained(P1 <:< P))
125+
123126
debug.println("P1 : " + P1.show)
124127
debug.println("P1 <:< P = " + res)
125128

0 commit comments

Comments
 (0)