Skip to content

Commit 5f1d384

Browse files
committed
Use isStatic and isFinal
1 parent df90c77 commit 5f1d384

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/kotlin/api/KotlinSignaturesLoading.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ private fun FieldNode.buildFieldSignature(
126126
companionClass = classes[companionName]
127127
foundAnnotations.addAll(companionClass?.visibleAnnotations.orEmpty())
128128
foundAnnotations.addAll(companionClass?.invisibleAnnotations.orEmpty())
129-
} else if (access.and(Opcodes.ACC_STATIC) != 0 && access.and(Opcodes.ACC_FINAL) != 0) {
129+
} else if (isStatic(access) && isFinal(access)) {
130130
companionClass = ownerClass.companionName(ownerClass.kotlinMetadata)?.let {
131131
classes[it]
132132
}
@@ -137,7 +137,7 @@ private fun FieldNode.buildFieldSignature(
137137
/*
138138
* The property was moved from the companion object. Take all the annotations from there
139139
* to be able to filter out the non-public markers.
140-
*
140+
*
141141
* See https://github.com/Kotlin/binary-compatibility-validator/issues/90
142142
*/
143143
foundAnnotations.addAll(companionClass!!.methods.annotationsFor(property.syntheticMethodForAnnotations))

0 commit comments

Comments
 (0)