CLI: improve diagnostic message format
- render the whole line where the error/warning points to, if any, and another line with '^', like other compilers do - lowercase diagnostic severity - decapitalize the message if it doesn't start with a proper name
This commit is contained in:
+27
-9
@@ -1,10 +1,28 @@
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (1, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (2, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (3, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (4, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (5, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (6, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder1.kt: (7, 5) Redeclaration: x
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder2.kt: (1, 5) Redeclaration: y
|
||||
ERROR: compiler/testData/cli/jvm/diagnosticsOrder2.kt: (2, 5) Redeclaration: y
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:1:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:2:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:3:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:4:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:5:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:6:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder1.kt:7:5: error: redeclaration: x
|
||||
val x = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder2.kt:1:5: error: redeclaration: y
|
||||
val y = 5
|
||||
^
|
||||
compiler/testData/cli/jvm/diagnosticsOrder2.kt:2:5: error: redeclaration: y
|
||||
val y = 5
|
||||
^
|
||||
COMPILATION_ERROR
|
||||
|
||||
Reference in New Issue
Block a user