From: Bernhard Urban Date: Tue, 30 Mar 2010 16:20:21 +0000 (+0200) Subject: ag: erste testfaelle X-Git-Url: http://wien.tomnetworks.com/gitweb/?p=testub10.git;a=commitdiff_plain;h=955990569ad113e06724c51f17d6ec78324a0ea8 ag: erste testfaelle --- diff --git a/ag/lewurm_00.3 b/ag/lewurm_00.3 new file mode 100644 index 0000000..25e8e2f --- /dev/null +++ b/ag/lewurm_00.3 @@ -0,0 +1,6 @@ +method f(a b c) + /* x nicht deklariert */ + if a < x then + c := 0x1; + end; +end; diff --git a/ag/lewurm_01.3 b/ag/lewurm_01.3 new file mode 100644 index 0000000..eda05e0 --- /dev/null +++ b/ag/lewurm_01.3 @@ -0,0 +1,8 @@ +method f(a b c) + if a < b then + var x := 0; + c := 1; + end; + /* x ist nicht im scope */ + x := x - 1; +end; diff --git a/ag/lewurm_02.3 b/ag/lewurm_02.3 new file mode 100644 index 0000000..c5fc09a --- /dev/null +++ b/ag/lewurm_02.3 @@ -0,0 +1,4 @@ +method f(a b c) + /* x ist (noch) nicht im scope */ + var x := x - 1; +end; diff --git a/ag/lewurm_03.0 b/ag/lewurm_03.0 new file mode 100644 index 0000000..1ac988c --- /dev/null +++ b/ag/lewurm_03.0 @@ -0,0 +1,5 @@ +struct a end; +method f(b c s) + /* lesender feldzugriff */ + var b := c*(s.a - 1); +end;