diff options
Diffstat (limited to 'shell/hush_test/hush-arith')
-rw-r--r-- | shell/hush_test/hush-arith/arith-postinc.right | 3 | ||||
-rwxr-xr-x | shell/hush_test/hush-arith/arith-postinc.tests | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/shell/hush_test/hush-arith/arith-postinc.right b/shell/hush_test/hush-arith/arith-postinc.right index c95ce02bf..5cd4ba6b4 100644 --- a/shell/hush_test/hush-arith/arith-postinc.right +++ b/shell/hush_test/hush-arith/arith-postinc.right | |||
@@ -2,4 +2,7 @@ | |||
2 | 1 1 | 2 | 1 1 |
3 | 1 1 | 3 | 1 1 |
4 | 1 1 | 4 | 1 1 |
5 | 6 6 | ||
6 | 7 7 | ||
7 | 7 7 | ||
5 | Ok:0 | 8 | Ok:0 |
diff --git a/shell/hush_test/hush-arith/arith-postinc.tests b/shell/hush_test/hush-arith/arith-postinc.tests index 3fd9bfed5..f2ae778df 100755 --- a/shell/hush_test/hush-arith/arith-postinc.tests +++ b/shell/hush_test/hush-arith/arith-postinc.tests | |||
@@ -2,4 +2,8 @@ echo 1 $((0++1)) | |||
2 | echo 1 $((0--1)) | 2 | echo 1 $((0--1)) |
3 | x=-1; echo 1 $((0-$x)) | 3 | x=-1; echo 1 $((0-$x)) |
4 | x=+1; echo 1 $((0+$x)) | 4 | x=+1; echo 1 $((0+$x)) |
5 | a=3 | ||
6 | echo 6 $((a+++3)) # a++ + 3 | ||
7 | echo 7 $(((a)+++3)) # a + + + 3 | ||
8 | echo 7 $(((a)+++3)) # a + + + 3 | ||
5 | echo Ok:$? | 9 | echo Ok:$? |