Files
kotlin-fork/compiler/testData/diagnostics/tests/declarationChecks/propertyInPackageHasNoInheritVisibility.kt
T
Mikhail Glukhikh 4bd48c4796 Regular modifier checker implemented (initial version). A set of tests fixed accordingly.
Most of modifier diagnostic is expressed by REDUNDANT_MODIFIER, INCOMPATIBLE_MODIFIERS, REPEATED_MODIFIER, WRONG_MODIFIER_TARGET, WRONG_MODIFIER_PARENT.
A set of modifier diagnostics is not in use now (but not deleted yet).
2015-08-03 19:41:50 +03:00

10 lines
186 B
Kotlin
Vendored

package d
<!WRONG_MODIFIER_TARGET!>override<!> val f : ()-> Int = { 12 }
fun test() {
f()
}
var g: Int = 1
<!WRONG_MODIFIER_CONTAINING_DECLARATION!>protected<!> set(i: Int) {}