[FIR] Add the new test set to render diagnostics from IR const evaluator
This commit is contained in:
+5
@@ -0,0 +1,5 @@
|
||||
/exceptionFromInterpreter.kt:(197,200): error: Cannot evaluate constant expression: / by zero
|
||||
|
||||
/exceptionFromInterpreter.kt:(239,254): error: Cannot evaluate constant expression: marginPrefix must be non-blank string.
|
||||
|
||||
/exceptionFromInterpreter.kt:(305,308): error: Cannot evaluate constant expression: / by zero
|
||||
@@ -0,0 +1,14 @@
|
||||
// FIR_IDENTICAL
|
||||
// !RENDER_IR_DIAGNOSTICS_FULL_TEXT
|
||||
// !LANGUAGE: +IntrinsicConstEvaluation
|
||||
// TARGET_BACKEND: JVM_IR
|
||||
// !DIAGNOSTICS: -DIVISION_BY_ZERO
|
||||
// WITH_STDLIB
|
||||
|
||||
const val divideByZero = 1 <!EVALUATION_ERROR!>/ 0<!>
|
||||
const val trimMarginException = "123".<!EVALUATION_ERROR!>trimMargin(" ")<!>
|
||||
|
||||
annotation class A(val i: Int, val b: Int)
|
||||
|
||||
@A(1 <!EVALUATION_ERROR!>/ 0<!>, 2)
|
||||
fun foo() {}
|
||||
Reference in New Issue
Block a user