From a317c8a803b8414b33c7238928e65fb99a721178 Mon Sep 17 00:00:00 2001 From: Dmitriy Novozhilov Date: Wed, 17 Jun 2020 18:43:58 +0300 Subject: [PATCH] [FIR-TEST] Update testdata due to unresolved KT-36056 --- .../flowInlining/nestedTryCatchFinally.fir.kt | 10 +++++----- .../controlflow/flowInlining/nestedTryCatchs.fir.kt | 4 ++-- .../controlflow/flowInlining/throwIfNotCalled.fir.kt | 2 +- .../contracts/controlflow/flowInlining/tryCatch.fir.kt | 4 ++-- .../controlflow/flowInlining/tryCatchFinally.fir.kt | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchFinally.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchFinally.fir.kt index f9df882365a..d09ec05a883 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchFinally.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchFinally.fir.kt @@ -45,7 +45,7 @@ fun outerFinallyInitializes() { } // Properly initialized - x.inc() + x.inc() } fun innerFinallyInitializes() { @@ -62,14 +62,14 @@ fun innerFinallyInitializes() { } // Properly initialized - x.inc() + x.inc() } catch (e: java.lang.Exception) { log() } // Still can be unitialized because we don't know what can happen in try-block // (e.g., OutOfMemory exception could've happened even before myRun was executed) - x.inc() + x.inc() } @@ -87,12 +87,12 @@ fun innerFinallyInitializesOuterRethrows() { } // Properly initialized - x.inc() + x.inc() } catch (e: java.lang.Exception) { log() throw e } // Guaranteed to be initialized because all catch-clauses are rethrowing - x.inc() + x.inc() } \ No newline at end of file diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchs.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchs.fir.kt index 0376bb6d27f..40b40cd4c83 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchs.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/nestedTryCatchs.fir.kt @@ -30,7 +30,7 @@ fun innerTryCatchInitializes() { } } // Can get here only when inlined lambda exited properly, i.e. x is initialized - x.inc() + x.inc() outerComputation() } catch (e: java.lang.Exception) { @@ -43,5 +43,5 @@ fun innerTryCatchInitializes() { x = 42 } // Here x=I because outer try-catch either exited normally (x=I) or catched exception (x=I, with reassingment, though) - x.inc() + x.inc() } \ No newline at end of file diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/throwIfNotCalled.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/throwIfNotCalled.fir.kt index b3ba1db5f40..61c2f902434 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/throwIfNotCalled.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/throwIfNotCalled.fir.kt @@ -26,7 +26,7 @@ fun throwIfNotCalled() { } // x *is* initialized here, because if myRun was never called -> exception // were thrown and control flow wouldn't be here - println(x) + println(x) } fun catchThrowIfNotCalled() { diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatch.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatch.fir.kt index ec05a6d18fc..2e864fbe2f3 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatch.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatch.fir.kt @@ -43,7 +43,7 @@ fun possibleReassignmentInTryCatch() { } x.inc() } - x.inc() + x.inc() } fun tryCatchOuter() { @@ -53,6 +53,6 @@ fun tryCatchOuter() { x.inc() } catch (e: java.lang.Exception) { - x.inc() + x.inc() } } diff --git a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatchFinally.fir.kt b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatchFinally.fir.kt index c62c45b5a24..2b1f4f23c98 100644 --- a/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatchFinally.fir.kt +++ b/compiler/testData/diagnostics/testsWithStdLib/contracts/controlflow/flowInlining/tryCatchFinally.fir.kt @@ -30,5 +30,5 @@ fun innerTryCatchFinally() { } } - x.inc() + x.inc() } \ No newline at end of file