diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2018-10-08 19:36:29 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2018-10-08 19:36:29 (GMT) |
commit | df93fd85a35f40f47d2d6b9a7ec9326346b3b6b4 (patch) | |
tree | 6744c6bef5b033702c89aa10637679f26083fa6d /tests/expr-old.test | |
parent | 1812305cb35d0096d50f9b1e7c1c368f230b6f07 (diff) | |
parent | e7a40e1084f2d3c711a2aeccccb9b9b40b0c37e7 (diff) | |
download | tcl-df93fd85a35f40f47d2d6b9a7ec9326346b3b6b4.zip tcl-df93fd85a35f40f47d2d6b9a7ec9326346b3b6b4.tar.gz tcl-df93fd85a35f40f47d2d6b9a7ec9326346b3b6b4.tar.bz2 |
Merge 8.7
Diffstat (limited to 'tests/expr-old.test')
-rw-r--r-- | tests/expr-old.test | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/tests/expr-old.test b/tests/expr-old.test index 50040a5..9f9ad99 100644 --- a/tests/expr-old.test +++ b/tests/expr-old.test @@ -814,10 +814,10 @@ test expr-old-32.32 {math functions in expressions} { } {-1} test expr-old-32.33 {math functions in expressions} { expr int(1e60) -} 0 +} 999999999999999949387135297074018866963645011013410073083904 test expr-old-32.34 {math functions in expressions} { expr int(-1e60) -} 0 +} -999999999999999949387135297074018866963645011013410073083904 test expr-old-32.35 {math functions in expressions} { expr round(1.49) } {1} @@ -1036,8 +1036,8 @@ test expr-old-37.8 {Tcl_ExprLong handles overflows} testexprlong { testexprlong -0x80000000 } {This is a result: -2147483648} test expr-old-37.9 {Tcl_ExprLong handles overflows} {testexprlong longIs32bit} { - testexprlong -0xffffffff -} {This is a result: 1} + testexprlong -0x7fffffff +} {This is a result: -2147483647} test expr-old-37.10 {Tcl_ExprLong handles overflows} \ -constraints {testexprlong longIs32bit} \ -match glob \ @@ -1061,9 +1061,13 @@ test expr-old-37.13 {Tcl_ExprLong handles overflows} \ test expr-old-37.14 {Tcl_ExprLong handles overflows} testexprlong { testexprlong -2147483648. } {This is a result: -2147483648} -test expr-old-37.15 {Tcl_ExprLong handles overflows} {testexprlong longIs32bit} { - testexprlong -4294967295. -} {This is a result: 1} +test expr-old-37.15 {Tcl_ExprLong handles overflows} \ + -constraints {testexprlong longIs32bit} \ + -match glob \ + -body { + list [catch {testexprlong -2147483649.} result] $result + } \ + -result {1 {integer value too large to represent*}} test expr-old-37.16 {Tcl_ExprLong handles overflows} \ -constraints {testexprlong longIs32bit} \ -match glob \ |