diff options
author | Tristan Gingold <tgingold@free.fr> | 2020-07-25 09:02:42 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2020-07-25 11:28:50 +0200 |
commit | 0795210282e6ddb6190a4a16bca73aad18717cb7 (patch) | |
tree | 2d81240f8c7c3795506bbd5be050c214619f83a6 /src/ortho/oread | |
parent | 5716ac056b0bbcec8bc6059843a21a3eb36c653d (diff) | |
download | ghdl-0795210282e6ddb6190a4a16bca73aad18717cb7.tar.gz ghdl-0795210282e6ddb6190a4a16bca73aad18717cb7.tar.bz2 ghdl-0795210282e6ddb6190a4a16bca73aad18717cb7.zip |
src/ortho/oread/tests: fix 2 tests.
Diffstat (limited to 'src/ortho/oread')
-rw-r--r-- | src/ortho/oread/tests/local2.on | 22 | ||||
-rw-r--r-- | src/ortho/oread/tests/run_declare2.on | 32 |
2 files changed, 27 insertions, 27 deletions
diff --git a/src/ortho/oread/tests/local2.on b/src/ortho/oread/tests/local2.on index e06cdb8ea..5f8ece31e 100644 --- a/src/ortho/oread/tests/local2.on +++ b/src/ortho/oread/tests/local2.on @@ -1,15 +1,15 @@ -type __ghdl_integer is signed (32); +TYPE __ghdl_integer IS SIGNED (32); -public function test_arg (v : __ghdl_integer) return __ghdl_integer -declare - local var w : __ghdl_integer; -begin +PUBLIC FUNCTION test_arg (v : __ghdl_integer) RETURN __ghdl_integer +DECLARE + LOCAL VAR w : __ghdl_integer; +BEGIN w := v; - declare - local var z : __ghdl_integer; - begin + DECLARE + LOCAL VAR z : __ghdl_integer; + BEGIN z := v +# w; w := z; - end; - return w; -end; + END; + RETURN w; +END; diff --git a/src/ortho/oread/tests/run_declare2.on b/src/ortho/oread/tests/run_declare2.on index ae38b660d..bd321fc53 100644 --- a/src/ortho/oread/tests/run_declare2.on +++ b/src/ortho/oread/tests/run_declare2.on @@ -1,21 +1,21 @@ -type __ghdl_int is unsigned (32); +TYPE __ghdl_int IS UNSIGNED (32); -public function main (a : __ghdl_int) return __ghdl_int -declare - local var b : __ghdl_int; - local var z : __ghdl_int; -begin +PUBLIC FUNCTION main (a : __ghdl_int) RETURN __ghdl_int +DECLARE + LOCAL VAR b : __ghdl_int; + LOCAL VAR z : __ghdl_int; +BEGIN b := a; - declare - local var c : __ghdl_int; - begin + DECLARE + LOCAL VAR c : __ghdl_int; + BEGIN c := b; - end; - declare - local var d : __ghdl_int; - begin + END; + DECLARE + LOCAL VAR d : __ghdl_int; + BEGIN d := b; z := d; - end; - return z +# 1; -end; + END; + RETURN z +# 1; +END; |