From be85547e3d15ae2c19318236bd96074b9073b7d6 Mon Sep 17 00:00:00 2001 From: Snafu Date: Sun, 2 May 2010 23:06:21 +0200 Subject: [PATCH] Eigene Testfaelle. lewurm_01.call und lewurm_02.call ausgebessert. --- codea/lewurm_01.call | 4 ++-- codea/lewurm_02.call | 4 ++-- codea/snafu_00.0 | 11 +++++++++++ codea/snafu_00.call | 5 +++++ codea/snafu_01.0 | 11 +++++++++++ codea/snafu_01.call | 5 +++++ codea/snafu_02.0 | 7 +++++++ codea/snafu_02.call | 4 ++++ 8 files changed, 47 insertions(+), 4 deletions(-) create mode 100644 codea/snafu_00.0 create mode 100644 codea/snafu_00.call create mode 100644 codea/snafu_01.0 create mode 100644 codea/snafu_01.call create mode 100644 codea/snafu_02.0 create mode 100644 codea/snafu_02.call diff --git a/codea/lewurm_01.call b/codea/lewurm_01.call index 57a0ec6..4484864 100644 --- a/codea/lewurm_01.call +++ b/codea/lewurm_01.call @@ -1,2 +1,2 @@ -extern long f(long); -RET(f(5)==5); +extern long f(long, long); +RET(f(0xDEAD, 5)==5); diff --git a/codea/lewurm_02.call b/codea/lewurm_02.call index 2861bb0..84fad81 100644 --- a/codea/lewurm_02.call +++ b/codea/lewurm_02.call @@ -1,2 +1,2 @@ -extern long f(long); -RET(f(-3)==-3); +extern long f(long, long); +RET(f(0xDEAD, -3)==-3); diff --git a/codea/snafu_00.0 b/codea/snafu_00.0 new file mode 100644 index 0000000..3806e12 --- /dev/null +++ b/codea/snafu_00.0 @@ -0,0 +1,11 @@ +method foo(a b c) + return a; +end; + +method bar(a b c) + return b; +end; + +method foobar(a b c) + return c; +end; diff --git a/codea/snafu_00.call b/codea/snafu_00.call new file mode 100644 index 0000000..000b197 --- /dev/null +++ b/codea/snafu_00.call @@ -0,0 +1,5 @@ +extern long foo(long this, long, long, long); +extern long bar(long this, long, long, long); +extern long foobar(long this, long, long, long); + +RET( (foo(0xDEAD, 3, 4, 5) == 3) && (bar(0xDEAD, 3, 4, 5) == 4) && (foobar(0xDEAD, 3, 4, 5) == 5)); diff --git a/codea/snafu_01.0 b/codea/snafu_01.0 new file mode 100644 index 0000000..3383891 --- /dev/null +++ b/codea/snafu_01.0 @@ -0,0 +1,11 @@ +method a() + return 5 - 3; +end; + +method b(x) + return 5 - x; +end; + +method c(x) + return x - 3; +end; diff --git a/codea/snafu_01.call b/codea/snafu_01.call new file mode 100644 index 0000000..06d5289 --- /dev/null +++ b/codea/snafu_01.call @@ -0,0 +1,5 @@ +extern long a(long this); +extern long b(long this, long x); +extern long c(long this, long x); + +RET( (a(0xDEAD) == 2) && (b(0xDEAD, 23) == -18) && (c(0xDEAD, 23) == 20)); diff --git a/codea/snafu_02.0 b/codea/snafu_02.0 new file mode 100644 index 0000000..7871f2e --- /dev/null +++ b/codea/snafu_02.0 @@ -0,0 +1,7 @@ +method q(x y) + return 5 - ((x - 3) - y); +end; + +method r(x y) + return (x - y) - 10; +end; diff --git a/codea/snafu_02.call b/codea/snafu_02.call new file mode 100644 index 0000000..4e9d749 --- /dev/null +++ b/codea/snafu_02.call @@ -0,0 +1,4 @@ +extern long q(long this, long, long); +extern long r(long this, long, long); + +RET((q(0xDEAD, 33, 15) == -10) && (r(0xDEAD, 33, 15) == 8)); -- 2.25.1