FIR checkers: report VAL_REASSIGNMENT for assignment operators
Currently VAL_REASSIGNMENT are only reported on direct assignments. Reassignments in the form of, for example, `+=` are reported as `VARIABLE_EXPECTED`, which differs from FE1.0.
This commit is contained in:
committed by
Mikhail Glukhikh
parent
b87a943efd
commit
fc8d0e3ee0
+4
-4
@@ -68,16 +68,16 @@ class Test1 {
|
||||
|
||||
init {
|
||||
inlineMe {
|
||||
<!VARIABLE_EXPECTED!>a<!> += "allowed"
|
||||
<!VAL_REASSIGNMENT!>a<!> += "allowed"
|
||||
}
|
||||
crossinlineMe {
|
||||
<!VARIABLE_EXPECTED!>b<!> += "not allowed"
|
||||
<!VAL_REASSIGNMENT!>b<!> += "not allowed"
|
||||
}
|
||||
noinlineMe {
|
||||
<!VARIABLE_EXPECTED!>c<!> += "not allowed"
|
||||
<!VAL_REASSIGNMENT!>c<!> += "not allowed"
|
||||
}
|
||||
notinline {
|
||||
<!VARIABLE_EXPECTED!>d<!> += "not allowed"
|
||||
<!VAL_REASSIGNMENT!>d<!> += "not allowed"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user