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).
This commit is contained in:
Mikhail Glukhikh
2015-06-16 13:08:05 +03:00
parent faac06ff7e
commit 4bd48c4796
67 changed files with 588 additions and 616 deletions
@@ -4,10 +4,10 @@ class T {
fun baz() = 1
}
<!ILLEGAL_MODIFIER!>override<!> fun zzz() {}
<!WRONG_MODIFIER_TARGET!>override<!> fun zzz() {}
fun foo(t: T) {
<!ILLEGAL_MODIFIER!>override<!> fun T.baz() = 2
<!WRONG_MODIFIER_TARGET!>override<!> fun T.baz() = 2
// was "Visibility is unknown yet exception"
t.baz()