From 3915d2466002a29b011675661121c90574b57eaa Mon Sep 17 00:00:00 2001 From: Stepan Koltsov Date: Mon, 21 Nov 2011 14:07:11 +0400 Subject: [PATCH] more tests for backing fields --- .../quick/UninitializedOrReassignedVariables.jet | 3 +-- .../quick/backingField/ReadNonexistentDeclaredInHigher.jet | 7 +++++++ .../backingField/WriteNonexistentDeclaredInHigher.jet | 7 +++++++ 3 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 compiler/testData/checkerWithErrorTypes/quick/backingField/ReadNonexistentDeclaredInHigher.jet create mode 100644 compiler/testData/checkerWithErrorTypes/quick/backingField/WriteNonexistentDeclaredInHigher.jet diff --git a/compiler/testData/checkerWithErrorTypes/quick/UninitializedOrReassignedVariables.jet b/compiler/testData/checkerWithErrorTypes/quick/UninitializedOrReassignedVariables.jet index 548e67dece9..17ddcc58a79 100644 --- a/compiler/testData/checkerWithErrorTypes/quick/UninitializedOrReassignedVariables.jet +++ b/compiler/testData/checkerWithErrorTypes/quick/UninitializedOrReassignedVariables.jet @@ -129,7 +129,6 @@ class AnonymousInitializers(var a: String, val b: String) { { x = 11 - $y = 11 z = 10 } @@ -350,4 +349,4 @@ fun test(m : M) { fun test1(m : M) { m.x++ m.y-- -} \ No newline at end of file +} diff --git a/compiler/testData/checkerWithErrorTypes/quick/backingField/ReadNonexistentDeclaredInHigher.jet b/compiler/testData/checkerWithErrorTypes/quick/backingField/ReadNonexistentDeclaredInHigher.jet new file mode 100644 index 00000000000..1ec73f2984e --- /dev/null +++ b/compiler/testData/checkerWithErrorTypes/quick/backingField/ReadNonexistentDeclaredInHigher.jet @@ -0,0 +1,7 @@ +val y = 1 + +class A() { + { + val x = $y + } +} diff --git a/compiler/testData/checkerWithErrorTypes/quick/backingField/WriteNonexistentDeclaredInHigher.jet b/compiler/testData/checkerWithErrorTypes/quick/backingField/WriteNonexistentDeclaredInHigher.jet new file mode 100644 index 00000000000..039a381fd55 --- /dev/null +++ b/compiler/testData/checkerWithErrorTypes/quick/backingField/WriteNonexistentDeclaredInHigher.jet @@ -0,0 +1,7 @@ +val y = 1 + +class A() { + { + $y = 1 + } +}