Quick fix for enum entry delimiter syntax fix, together with a set of tests.

Possible NPE in getNextSiblingIgnoringWhitespace fixed. Some warnings also removed.
Last comma is replaced by semicolon. Comments are taken into account.
This commit is contained in:
Mikhail Glukhikh
2015-05-08 16:29:36 +03:00
parent da3d083dc0
commit edd269f5ff
27 changed files with 372 additions and 18 deletions
@@ -0,0 +1,22 @@
// "Insert lacking comma(s) / semicolon(s) in the whole project" "true"
enum class First {
RED, GREEN,
BLUE
}
enum class Second(val code: Int) {
NORTH(2), SOUTH(4),
EAST(6), WEST(8)
}
enum class Third {
OK {
override fun diag(): String = "OK"
},
ERROR {
override fun diag(): String = "Failed"
};
open fun diag(): String = ""
}