summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2015-04-06 14:30:05 +0300
committerDmitry Stogov <dmitry@zend.com>2015-04-06 14:30:05 +0300
commitcae0147ed3ceb55fcb1bc059b8e8ea6a36ea69a8 (patch)
tree4ca16379ac8d5cab749f07747e2599ee23a4d175 /tests
parentcaf9219dea58dcc6ef6da2b3b86a1e9808363bff (diff)
downloadphp-git-cae0147ed3ceb55fcb1bc059b8e8ea6a36ea69a8.tar.gz
Fixed weird operators behavior. Division by zero now emits warning and returns +/-INF, modulo by zero and intdid() throws an exception, shifts by negative offset throw exceptions. Compile-time evaluation of division by zero is disabled.
Diffstat (limited to 'tests')
-rw-r--r--tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt202
-rw-r--r--tests/lang/operators/bitwiseShiftLeft_variationStr.phpt64
-rw-r--r--tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt64
-rw-r--r--tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt202
-rw-r--r--tests/lang/operators/bitwiseShiftRight_variationStr.phpt64
-rw-r--r--tests/lang/operators/divide_basiclong_64bit.phpt30
-rw-r--r--tests/lang/operators/divide_variationStr.phpt84
-rw-r--r--tests/lang/operators/modulus_basiclong_64bit.phpt46
-rw-r--r--tests/lang/operators/modulus_variationStr.phpt92
9 files changed, 444 insertions, 404 deletions
diff --git a/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt b/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt
index c462e9b732..556d8e3444 100644
--- a/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt
+++ b/tests/lang/operators/bitwiseShiftLeft_basiclong_64bit.phpt
@@ -24,15 +24,23 @@ error_reporting(E_ERROR);
foreach ($longVals as $longVal) {
foreach($otherVals as $otherVal) {
- echo "--- testing: $longVal << $otherVal ---\n";
- var_dump($longVal<<$otherVal);
+ echo "--- testing: $longVal << $otherVal ---\n";
+ try {
+ var_dump($longVal<<$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
foreach ($otherVals as $otherVal) {
foreach($longVals as $longVal) {
- echo "--- testing: $otherVal << $longVal ---\n";
- var_dump($otherVal<<$longVal);
+ echo "--- testing: $otherVal << $longVal ---\n";
+ try {
+ var_dump($otherVal<<$longVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -44,7 +52,7 @@ int(9223372036854775807)
--- testing: 9223372036854775807 << 1 ---
int(-2)
--- testing: 9223372036854775807 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 7 ---
int(-128)
--- testing: 9223372036854775807 << 9 ---
@@ -52,7 +60,7 @@ int(-512)
--- testing: 9223372036854775807 << 65 ---
int(0)
--- testing: 9223372036854775807 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 2147483647 ---
int(0)
--- testing: 9223372036854775807 << 9223372036854775807 ---
@@ -62,7 +70,7 @@ int(-9223372036854775808)
--- testing: -9223372036854775808 << 1 ---
int(0)
--- testing: -9223372036854775808 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775808 << 7 ---
int(0)
--- testing: -9223372036854775808 << 9 ---
@@ -70,7 +78,7 @@ int(0)
--- testing: -9223372036854775808 << 65 ---
int(0)
--- testing: -9223372036854775808 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775808 << 2147483647 ---
int(0)
--- testing: -9223372036854775808 << 9223372036854775807 ---
@@ -80,7 +88,7 @@ int(2147483647)
--- testing: 2147483647 << 1 ---
int(4294967294)
--- testing: 2147483647 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 7 ---
int(274877906816)
--- testing: 2147483647 << 9 ---
@@ -88,7 +96,7 @@ int(1099511627264)
--- testing: 2147483647 << 65 ---
int(0)
--- testing: 2147483647 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 2147483647 ---
int(0)
--- testing: 2147483647 << 9223372036854775807 ---
@@ -98,7 +106,7 @@ int(-2147483648)
--- testing: -2147483648 << 1 ---
int(-4294967296)
--- testing: -2147483648 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483648 << 7 ---
int(-274877906944)
--- testing: -2147483648 << 9 ---
@@ -106,7 +114,7 @@ int(-1099511627776)
--- testing: -2147483648 << 65 ---
int(0)
--- testing: -2147483648 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483648 << 2147483647 ---
int(0)
--- testing: -2147483648 << 9223372036854775807 ---
@@ -116,7 +124,7 @@ int(9223372034707292160)
--- testing: 9223372034707292160 << 1 ---
int(-4294967296)
--- testing: 9223372034707292160 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372034707292160 << 7 ---
int(-274877906944)
--- testing: 9223372034707292160 << 9 ---
@@ -124,7 +132,7 @@ int(-1099511627776)
--- testing: 9223372034707292160 << 65 ---
int(0)
--- testing: 9223372034707292160 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372034707292160 << 2147483647 ---
int(0)
--- testing: 9223372034707292160 << 9223372036854775807 ---
@@ -134,7 +142,7 @@ int(-9223372034707292160)
--- testing: -9223372034707292160 << 1 ---
int(4294967296)
--- testing: -9223372034707292160 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372034707292160 << 7 ---
int(274877906944)
--- testing: -9223372034707292160 << 9 ---
@@ -142,7 +150,7 @@ int(1099511627776)
--- testing: -9223372034707292160 << 65 ---
int(0)
--- testing: -9223372034707292160 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372034707292160 << 2147483647 ---
int(0)
--- testing: -9223372034707292160 << 9223372036854775807 ---
@@ -152,7 +160,7 @@ int(2147483648)
--- testing: 2147483648 << 1 ---
int(4294967296)
--- testing: 2147483648 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483648 << 7 ---
int(274877906944)
--- testing: 2147483648 << 9 ---
@@ -160,7 +168,7 @@ int(1099511627776)
--- testing: 2147483648 << 65 ---
int(0)
--- testing: 2147483648 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483648 << 2147483647 ---
int(0)
--- testing: 2147483648 << 9223372036854775807 ---
@@ -170,7 +178,7 @@ int(-2147483649)
--- testing: -2147483649 << 1 ---
int(-4294967298)
--- testing: -2147483649 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483649 << 7 ---
int(-274877907072)
--- testing: -2147483649 << 9 ---
@@ -178,7 +186,7 @@ int(-1099511628288)
--- testing: -2147483649 << 65 ---
int(0)
--- testing: -2147483649 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483649 << 2147483647 ---
int(0)
--- testing: -2147483649 << 9223372036854775807 ---
@@ -188,7 +196,7 @@ int(4294967294)
--- testing: 4294967294 << 1 ---
int(8589934588)
--- testing: 4294967294 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967294 << 7 ---
int(549755813632)
--- testing: 4294967294 << 9 ---
@@ -196,7 +204,7 @@ int(2199023254528)
--- testing: 4294967294 << 65 ---
int(0)
--- testing: 4294967294 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967294 << 2147483647 ---
int(0)
--- testing: 4294967294 << 9223372036854775807 ---
@@ -206,7 +214,7 @@ int(4294967295)
--- testing: 4294967295 << 1 ---
int(8589934590)
--- testing: 4294967295 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967295 << 7 ---
int(549755813760)
--- testing: 4294967295 << 9 ---
@@ -214,7 +222,7 @@ int(2199023255040)
--- testing: 4294967295 << 65 ---
int(0)
--- testing: 4294967295 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967295 << 2147483647 ---
int(0)
--- testing: 4294967295 << 9223372036854775807 ---
@@ -224,7 +232,7 @@ int(4294967293)
--- testing: 4294967293 << 1 ---
int(8589934586)
--- testing: 4294967293 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967293 << 7 ---
int(549755813504)
--- testing: 4294967293 << 9 ---
@@ -232,7 +240,7 @@ int(2199023254016)
--- testing: 4294967293 << 65 ---
int(0)
--- testing: 4294967293 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967293 << 2147483647 ---
int(0)
--- testing: 4294967293 << 9223372036854775807 ---
@@ -242,7 +250,7 @@ int(9223372036854775806)
--- testing: 9223372036854775806 << 1 ---
int(-4)
--- testing: 9223372036854775806 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775806 << 7 ---
int(-256)
--- testing: 9223372036854775806 << 9 ---
@@ -250,7 +258,7 @@ int(-1024)
--- testing: 9223372036854775806 << 65 ---
int(0)
--- testing: 9223372036854775806 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775806 << 2147483647 ---
int(0)
--- testing: 9223372036854775806 << 9223372036854775807 ---
@@ -260,7 +268,7 @@ int(-9223372036854775808)
--- testing: 9.2233720368548E+18 << 1 ---
int(0)
--- testing: 9.2233720368548E+18 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9.2233720368548E+18 << 7 ---
int(0)
--- testing: 9.2233720368548E+18 << 9 ---
@@ -268,7 +276,7 @@ int(0)
--- testing: 9.2233720368548E+18 << 65 ---
int(0)
--- testing: 9.2233720368548E+18 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9.2233720368548E+18 << 2147483647 ---
int(0)
--- testing: 9.2233720368548E+18 << 9223372036854775807 ---
@@ -278,7 +286,7 @@ int(-9223372036854775807)
--- testing: -9223372036854775807 << 1 ---
int(2)
--- testing: -9223372036854775807 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775807 << 7 ---
int(128)
--- testing: -9223372036854775807 << 9 ---
@@ -286,7 +294,7 @@ int(512)
--- testing: -9223372036854775807 << 65 ---
int(0)
--- testing: -9223372036854775807 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775807 << 2147483647 ---
int(0)
--- testing: -9223372036854775807 << 9223372036854775807 ---
@@ -296,7 +304,7 @@ int(-9223372036854775808)
--- testing: -9.2233720368548E+18 << 1 ---
int(0)
--- testing: -9.2233720368548E+18 << -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9.2233720368548E+18 << 7 ---
int(0)
--- testing: -9.2233720368548E+18 << 9 ---
@@ -304,7 +312,7 @@ int(0)
--- testing: -9.2233720368548E+18 << 65 ---
int(0)
--- testing: -9.2233720368548E+18 << -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9.2233720368548E+18 << 2147483647 ---
int(0)
--- testing: -9.2233720368548E+18 << 9223372036854775807 ---
@@ -312,19 +320,19 @@ int(0)
--- testing: 0 << 9223372036854775807 ---
int(0)
--- testing: 0 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << 2147483647 ---
int(0)
--- testing: 0 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << 9223372034707292160 ---
int(0)
--- testing: 0 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << 2147483648 ---
int(0)
--- testing: 0 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << 4294967294 ---
int(0)
--- testing: 0 << 4294967295 ---
@@ -334,27 +342,27 @@ int(0)
--- testing: 0 << 9223372036854775806 ---
int(0)
--- testing: 0 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << 9223372036854775807 ---
int(0)
--- testing: 1 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << 2147483647 ---
int(0)
--- testing: 1 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << 9223372034707292160 ---
int(0)
--- testing: 1 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << 2147483648 ---
int(0)
--- testing: 1 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << 4294967294 ---
int(0)
--- testing: 1 << 4294967295 ---
@@ -364,27 +372,27 @@ int(0)
--- testing: 1 << 9223372036854775806 ---
int(0)
--- testing: 1 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << 9223372036854775807 ---
int(0)
--- testing: -1 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << 2147483647 ---
int(0)
--- testing: -1 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << 9223372034707292160 ---
int(0)
--- testing: -1 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << 2147483648 ---
int(0)
--- testing: -1 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << 4294967294 ---
int(0)
--- testing: -1 << 4294967295 ---
@@ -394,27 +402,27 @@ int(0)
--- testing: -1 << 9223372036854775806 ---
int(0)
--- testing: -1 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << 9223372036854775807 ---
int(0)
--- testing: 7 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << 2147483647 ---
int(0)
--- testing: 7 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << 9223372034707292160 ---
int(0)
--- testing: 7 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << 2147483648 ---
int(0)
--- testing: 7 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << 4294967294 ---
int(0)
--- testing: 7 << 4294967295 ---
@@ -424,27 +432,27 @@ int(0)
--- testing: 7 << 9223372036854775806 ---
int(0)
--- testing: 7 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << 9223372036854775807 ---
int(0)
--- testing: 9 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << 2147483647 ---
int(0)
--- testing: 9 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << 9223372034707292160 ---
int(0)
--- testing: 9 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << 2147483648 ---
int(0)
--- testing: 9 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << 4294967294 ---
int(0)
--- testing: 9 << 4294967295 ---
@@ -454,27 +462,27 @@ int(0)
--- testing: 9 << 9223372036854775806 ---
int(0)
--- testing: 9 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << 9223372036854775807 ---
int(0)
--- testing: 65 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << 2147483647 ---
int(0)
--- testing: 65 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << 9223372034707292160 ---
int(0)
--- testing: 65 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << 2147483648 ---
int(0)
--- testing: 65 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << 4294967294 ---
int(0)
--- testing: 65 << 4294967295 ---
@@ -484,27 +492,27 @@ int(0)
--- testing: 65 << 9223372036854775806 ---
int(0)
--- testing: 65 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << 9223372036854775807 ---
int(0)
--- testing: -44 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << 2147483647 ---
int(0)
--- testing: -44 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << 9223372034707292160 ---
int(0)
--- testing: -44 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << 2147483648 ---
int(0)
--- testing: -44 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << 4294967294 ---
int(0)
--- testing: -44 << 4294967295 ---
@@ -514,27 +522,27 @@ int(0)
--- testing: -44 << 9223372036854775806 ---
int(0)
--- testing: -44 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 9223372036854775807 ---
int(0)
--- testing: 2147483647 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 2147483647 ---
int(0)
--- testing: 2147483647 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 9223372034707292160 ---
int(0)
--- testing: 2147483647 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 2147483648 ---
int(0)
--- testing: 2147483647 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << 4294967294 ---
int(0)
--- testing: 2147483647 << 4294967295 ---
@@ -544,27 +552,27 @@ int(0)
--- testing: 2147483647 << 9223372036854775806 ---
int(0)
--- testing: 2147483647 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 9223372036854775807 ---
int(0)
--- testing: 9223372036854775807 << -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 2147483647 ---
int(0)
--- testing: 9223372036854775807 << -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 9223372034707292160 ---
int(0)
--- testing: 9223372036854775807 << -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 2147483648 ---
int(0)
--- testing: 9223372036854775807 << -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << 4294967294 ---
int(0)
--- testing: 9223372036854775807 << 4294967295 ---
@@ -574,9 +582,9 @@ int(0)
--- testing: 9223372036854775807 << 9223372036854775806 ---
int(0)
--- testing: 9223372036854775807 << 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 << -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
===DONE===
diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
index 4dff475eec..6a44c5d630 100644
--- a/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
+++ b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
@@ -16,8 +16,12 @@ error_reporting(E_ERROR);
foreach ($strVals as $strVal) {
foreach($strVals as $otherVal) {
- echo "--- testing: '$strVal' << '$otherVal' ---\n";
- var_dump(strVal<<$otherVal);
+ echo "--- testing: '$strVal' << '$otherVal' ---\n";
+ try {
+ var_dump(strVal<<$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -29,11 +33,11 @@ int(0)
--- testing: '0' << '65' ---
int(0)
--- testing: '0' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' << '1.2' ---
int(0)
--- testing: '0' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' << 'abc' ---
int(0)
--- testing: '0' << '123abc' ---
@@ -57,11 +61,11 @@ int(0)
--- testing: '65' << '65' ---
int(0)
--- testing: '65' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' << '1.2' ---
int(0)
--- testing: '65' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' << 'abc' ---
int(0)
--- testing: '65' << '123abc' ---
@@ -85,11 +89,11 @@ int(0)
--- testing: '-44' << '65' ---
int(0)
--- testing: '-44' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' << '1.2' ---
int(0)
--- testing: '-44' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' << 'abc' ---
int(0)
--- testing: '-44' << '123abc' ---
@@ -113,11 +117,11 @@ int(0)
--- testing: '1.2' << '65' ---
int(0)
--- testing: '1.2' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' << '1.2' ---
int(0)
--- testing: '1.2' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' << 'abc' ---
int(0)
--- testing: '1.2' << '123abc' ---
@@ -141,11 +145,11 @@ int(0)
--- testing: '-7.7' << '65' ---
int(0)
--- testing: '-7.7' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' << '1.2' ---
int(0)
--- testing: '-7.7' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' << 'abc' ---
int(0)
--- testing: '-7.7' << '123abc' ---
@@ -169,11 +173,11 @@ int(0)
--- testing: 'abc' << '65' ---
int(0)
--- testing: 'abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' << '1.2' ---
int(0)
--- testing: 'abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' << 'abc' ---
int(0)
--- testing: 'abc' << '123abc' ---
@@ -197,11 +201,11 @@ int(0)
--- testing: '123abc' << '65' ---
int(0)
--- testing: '123abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' << '1.2' ---
int(0)
--- testing: '123abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' << 'abc' ---
int(0)
--- testing: '123abc' << '123abc' ---
@@ -225,11 +229,11 @@ int(0)
--- testing: '123e5' << '65' ---
int(0)
--- testing: '123e5' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' << '1.2' ---
int(0)
--- testing: '123e5' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' << 'abc' ---
int(0)
--- testing: '123e5' << '123abc' ---
@@ -253,11 +257,11 @@ int(0)
--- testing: '123e5xyz' << '65' ---
int(0)
--- testing: '123e5xyz' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' << '1.2' ---
int(0)
--- testing: '123e5xyz' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' << 'abc' ---
int(0)
--- testing: '123e5xyz' << '123abc' ---
@@ -281,11 +285,11 @@ int(0)
--- testing: ' 123abc' << '65' ---
int(0)
--- testing: ' 123abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' << '1.2' ---
int(0)
--- testing: ' 123abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' << 'abc' ---
int(0)
--- testing: ' 123abc' << '123abc' ---
@@ -309,11 +313,11 @@ int(0)
--- testing: '123 abc' << '65' ---
int(0)
--- testing: '123 abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' << '1.2' ---
int(0)
--- testing: '123 abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' << 'abc' ---
int(0)
--- testing: '123 abc' << '123abc' ---
@@ -337,11 +341,11 @@ int(0)
--- testing: '123abc ' << '65' ---
int(0)
--- testing: '123abc ' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' << '1.2' ---
int(0)
--- testing: '123abc ' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' << 'abc' ---
int(0)
--- testing: '123abc ' << '123abc' ---
@@ -365,11 +369,11 @@ int(0)
--- testing: '3.4a' << '65' ---
int(0)
--- testing: '3.4a' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' << '1.2' ---
int(0)
--- testing: '3.4a' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' << 'abc' ---
int(0)
--- testing: '3.4a' << '123abc' ---
@@ -393,11 +397,11 @@ int(0)
--- testing: 'a5.9' << '65' ---
int(0)
--- testing: 'a5.9' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' << '1.2' ---
int(0)
--- testing: 'a5.9' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' << 'abc' ---
int(0)
--- testing: 'a5.9' << '123abc' ---
diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt
index 4e4cf0d7f7..1ae091461f 100644
--- a/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt
+++ b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt
@@ -16,8 +16,12 @@ error_reporting(E_ERROR);
foreach ($strVals as $strVal) {
foreach($strVals as $otherVal) {
- echo "--- testing: '$strVal' << '$otherVal' ---\n";
- var_dump($strVal<<$otherVal);
+ echo "--- testing: '$strVal' << '$otherVal' ---\n";
+ try {
+ var_dump($strVal<<$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -30,11 +34,11 @@ int(0)
--- testing: '0' << '65' ---
int(0)
--- testing: '0' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' << '1.2' ---
int(0)
--- testing: '0' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' << 'abc' ---
int(0)
--- testing: '0' << '123abc' ---
@@ -58,11 +62,11 @@ int(65)
--- testing: '65' << '65' ---
int(0)
--- testing: '65' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' << '1.2' ---
int(130)
--- testing: '65' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' << 'abc' ---
int(65)
--- testing: '65' << '123abc' ---
@@ -86,11 +90,11 @@ int(-44)
--- testing: '-44' << '65' ---
int(0)
--- testing: '-44' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' << '1.2' ---
int(-88)
--- testing: '-44' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' << 'abc' ---
int(-44)
--- testing: '-44' << '123abc' ---
@@ -114,11 +118,11 @@ int(1)
--- testing: '1.2' << '65' ---
int(0)
--- testing: '1.2' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' << '1.2' ---
int(2)
--- testing: '1.2' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' << 'abc' ---
int(1)
--- testing: '1.2' << '123abc' ---
@@ -142,11 +146,11 @@ int(-7)
--- testing: '-7.7' << '65' ---
int(0)
--- testing: '-7.7' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' << '1.2' ---
int(-14)
--- testing: '-7.7' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' << 'abc' ---
int(-7)
--- testing: '-7.7' << '123abc' ---
@@ -170,11 +174,11 @@ int(0)
--- testing: 'abc' << '65' ---
int(0)
--- testing: 'abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' << '1.2' ---
int(0)
--- testing: 'abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' << 'abc' ---
int(0)
--- testing: 'abc' << '123abc' ---
@@ -198,11 +202,11 @@ int(123)
--- testing: '123abc' << '65' ---
int(0)
--- testing: '123abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' << '1.2' ---
int(246)
--- testing: '123abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' << 'abc' ---
int(123)
--- testing: '123abc' << '123abc' ---
@@ -226,11 +230,11 @@ int(123)
--- testing: '123e5' << '65' ---
int(0)
--- testing: '123e5' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' << '1.2' ---
int(246)
--- testing: '123e5' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' << 'abc' ---
int(123)
--- testing: '123e5' << '123abc' ---
@@ -254,11 +258,11 @@ int(123)
--- testing: '123e5xyz' << '65' ---
int(0)
--- testing: '123e5xyz' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' << '1.2' ---
int(246)
--- testing: '123e5xyz' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' << 'abc' ---
int(123)
--- testing: '123e5xyz' << '123abc' ---
@@ -282,11 +286,11 @@ int(123)
--- testing: ' 123abc' << '65' ---
int(0)
--- testing: ' 123abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' << '1.2' ---
int(246)
--- testing: ' 123abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' << 'abc' ---
int(123)
--- testing: ' 123abc' << '123abc' ---
@@ -310,11 +314,11 @@ int(123)
--- testing: '123 abc' << '65' ---
int(0)
--- testing: '123 abc' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' << '1.2' ---
int(246)
--- testing: '123 abc' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' << 'abc' ---
int(123)
--- testing: '123 abc' << '123abc' ---
@@ -338,11 +342,11 @@ int(123)
--- testing: '123abc ' << '65' ---
int(0)
--- testing: '123abc ' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' << '1.2' ---
int(246)
--- testing: '123abc ' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' << 'abc' ---
int(123)
--- testing: '123abc ' << '123abc' ---
@@ -366,11 +370,11 @@ int(3)
--- testing: '3.4a' << '65' ---
int(0)
--- testing: '3.4a' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' << '1.2' ---
int(6)
--- testing: '3.4a' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' << 'abc' ---
int(3)
--- testing: '3.4a' << '123abc' ---
@@ -394,11 +398,11 @@ int(0)
--- testing: 'a5.9' << '65' ---
int(0)
--- testing: 'a5.9' << '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' << '1.2' ---
int(0)
--- testing: 'a5.9' << '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' << 'abc' ---
int(0)
--- testing: 'a5.9' << '123abc' ---
diff --git a/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt b/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt
index a2c3870cb5..9083f47b03 100644
--- a/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt
+++ b/tests/lang/operators/bitwiseShiftRight_basiclong_64bit.phpt
@@ -24,15 +24,23 @@ error_reporting(E_ERROR);
foreach ($longVals as $longVal) {
foreach($otherVals as $otherVal) {
- echo "--- testing: $longVal >> $otherVal ---\n";
- var_dump($longVal>>$otherVal);
+ echo "--- testing: $longVal >> $otherVal ---\n";
+ try {
+ var_dump($longVal>>$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
foreach ($otherVals as $otherVal) {
foreach($longVals as $longVal) {
- echo "--- testing: $otherVal >> $longVal ---\n";
- var_dump($otherVal>>$longVal);
+ echo "--- testing: $otherVal >> $longVal ---\n";
+ try {
+ var_dump($otherVal>>$longVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -44,7 +52,7 @@ int(9223372036854775807)
--- testing: 9223372036854775807 >> 1 ---
int(4611686018427387903)
--- testing: 9223372036854775807 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 7 ---
int(72057594037927935)
--- testing: 9223372036854775807 >> 9 ---
@@ -52,7 +60,7 @@ int(18014398509481983)
--- testing: 9223372036854775807 >> 65 ---
int(0)
--- testing: 9223372036854775807 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 2147483647 ---
int(0)
--- testing: 9223372036854775807 >> 9223372036854775807 ---
@@ -62,7 +70,7 @@ int(-9223372036854775808)
--- testing: -9223372036854775808 >> 1 ---
int(-4611686018427387904)
--- testing: -9223372036854775808 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775808 >> 7 ---
int(-72057594037927936)
--- testing: -9223372036854775808 >> 9 ---
@@ -70,7 +78,7 @@ int(-18014398509481984)
--- testing: -9223372036854775808 >> 65 ---
int(-1)
--- testing: -9223372036854775808 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775808 >> 2147483647 ---
int(-1)
--- testing: -9223372036854775808 >> 9223372036854775807 ---
@@ -80,7 +88,7 @@ int(2147483647)
--- testing: 2147483647 >> 1 ---
int(1073741823)
--- testing: 2147483647 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 7 ---
int(16777215)
--- testing: 2147483647 >> 9 ---
@@ -88,7 +96,7 @@ int(4194303)
--- testing: 2147483647 >> 65 ---
int(0)
--- testing: 2147483647 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 2147483647 ---
int(0)
--- testing: 2147483647 >> 9223372036854775807 ---
@@ -98,7 +106,7 @@ int(-2147483648)
--- testing: -2147483648 >> 1 ---
int(-1073741824)
--- testing: -2147483648 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483648 >> 7 ---
int(-16777216)
--- testing: -2147483648 >> 9 ---
@@ -106,7 +114,7 @@ int(-4194304)
--- testing: -2147483648 >> 65 ---
int(-1)
--- testing: -2147483648 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483648 >> 2147483647 ---
int(-1)
--- testing: -2147483648 >> 9223372036854775807 ---
@@ -116,7 +124,7 @@ int(9223372034707292160)
--- testing: 9223372034707292160 >> 1 ---
int(4611686017353646080)
--- testing: 9223372034707292160 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372034707292160 >> 7 ---
int(72057594021150720)
--- testing: 9223372034707292160 >> 9 ---
@@ -124,7 +132,7 @@ int(18014398505287680)
--- testing: 9223372034707292160 >> 65 ---
int(0)
--- testing: 9223372034707292160 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372034707292160 >> 2147483647 ---
int(0)
--- testing: 9223372034707292160 >> 9223372036854775807 ---
@@ -134,7 +142,7 @@ int(-9223372034707292160)
--- testing: -9223372034707292160 >> 1 ---
int(-4611686017353646080)
--- testing: -9223372034707292160 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372034707292160 >> 7 ---
int(-72057594021150720)
--- testing: -9223372034707292160 >> 9 ---
@@ -142,7 +150,7 @@ int(-18014398505287680)
--- testing: -9223372034707292160 >> 65 ---
int(-1)
--- testing: -9223372034707292160 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372034707292160 >> 2147483647 ---
int(-1)
--- testing: -9223372034707292160 >> 9223372036854775807 ---
@@ -152,7 +160,7 @@ int(2147483648)
--- testing: 2147483648 >> 1 ---
int(1073741824)
--- testing: 2147483648 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483648 >> 7 ---
int(16777216)
--- testing: 2147483648 >> 9 ---
@@ -160,7 +168,7 @@ int(4194304)
--- testing: 2147483648 >> 65 ---
int(0)
--- testing: 2147483648 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483648 >> 2147483647 ---
int(0)
--- testing: 2147483648 >> 9223372036854775807 ---
@@ -170,7 +178,7 @@ int(-2147483649)
--- testing: -2147483649 >> 1 ---
int(-1073741825)
--- testing: -2147483649 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483649 >> 7 ---
int(-16777217)
--- testing: -2147483649 >> 9 ---
@@ -178,7 +186,7 @@ int(-4194305)
--- testing: -2147483649 >> 65 ---
int(-1)
--- testing: -2147483649 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -2147483649 >> 2147483647 ---
int(-1)
--- testing: -2147483649 >> 9223372036854775807 ---
@@ -188,7 +196,7 @@ int(4294967294)
--- testing: 4294967294 >> 1 ---
int(2147483647)
--- testing: 4294967294 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967294 >> 7 ---
int(33554431)
--- testing: 4294967294 >> 9 ---
@@ -196,7 +204,7 @@ int(8388607)
--- testing: 4294967294 >> 65 ---
int(0)
--- testing: 4294967294 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967294 >> 2147483647 ---
int(0)
--- testing: 4294967294 >> 9223372036854775807 ---
@@ -206,7 +214,7 @@ int(4294967295)
--- testing: 4294967295 >> 1 ---
int(2147483647)
--- testing: 4294967295 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967295 >> 7 ---
int(33554431)
--- testing: 4294967295 >> 9 ---
@@ -214,7 +222,7 @@ int(8388607)
--- testing: 4294967295 >> 65 ---
int(0)
--- testing: 4294967295 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967295 >> 2147483647 ---
int(0)
--- testing: 4294967295 >> 9223372036854775807 ---
@@ -224,7 +232,7 @@ int(4294967293)
--- testing: 4294967293 >> 1 ---
int(2147483646)
--- testing: 4294967293 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967293 >> 7 ---
int(33554431)
--- testing: 4294967293 >> 9 ---
@@ -232,7 +240,7 @@ int(8388607)
--- testing: 4294967293 >> 65 ---
int(0)
--- testing: 4294967293 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 4294967293 >> 2147483647 ---
int(0)
--- testing: 4294967293 >> 9223372036854775807 ---
@@ -242,7 +250,7 @@ int(9223372036854775806)
--- testing: 9223372036854775806 >> 1 ---
int(4611686018427387903)
--- testing: 9223372036854775806 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775806 >> 7 ---
int(72057594037927935)
--- testing: 9223372036854775806 >> 9 ---
@@ -250,7 +258,7 @@ int(18014398509481983)
--- testing: 9223372036854775806 >> 65 ---
int(0)
--- testing: 9223372036854775806 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775806 >> 2147483647 ---
int(0)
--- testing: 9223372036854775806 >> 9223372036854775807 ---
@@ -260,7 +268,7 @@ int(-9223372036854775808)
--- testing: 9.2233720368548E+18 >> 1 ---
int(-4611686018427387904)
--- testing: 9.2233720368548E+18 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9.2233720368548E+18 >> 7 ---
int(-72057594037927936)
--- testing: 9.2233720368548E+18 >> 9 ---
@@ -268,7 +276,7 @@ int(-18014398509481984)
--- testing: 9.2233720368548E+18 >> 65 ---
int(-1)
--- testing: 9.2233720368548E+18 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9.2233720368548E+18 >> 2147483647 ---
int(-1)
--- testing: 9.2233720368548E+18 >> 9223372036854775807 ---
@@ -278,7 +286,7 @@ int(-9223372036854775807)
--- testing: -9223372036854775807 >> 1 ---
int(-4611686018427387904)
--- testing: -9223372036854775807 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775807 >> 7 ---
int(-72057594037927936)
--- testing: -9223372036854775807 >> 9 ---
@@ -286,7 +294,7 @@ int(-18014398509481984)
--- testing: -9223372036854775807 >> 65 ---
int(-1)
--- testing: -9223372036854775807 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9223372036854775807 >> 2147483647 ---
int(-1)
--- testing: -9223372036854775807 >> 9223372036854775807 ---
@@ -296,7 +304,7 @@ int(-9223372036854775808)
--- testing: -9.2233720368548E+18 >> 1 ---
int(-4611686018427387904)
--- testing: -9.2233720368548E+18 >> -1 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9.2233720368548E+18 >> 7 ---
int(-72057594037927936)
--- testing: -9.2233720368548E+18 >> 9 ---
@@ -304,7 +312,7 @@ int(-18014398509481984)
--- testing: -9.2233720368548E+18 >> 65 ---
int(-1)
--- testing: -9.2233720368548E+18 >> -44 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -9.2233720368548E+18 >> 2147483647 ---
int(-1)
--- testing: -9.2233720368548E+18 >> 9223372036854775807 ---
@@ -312,19 +320,19 @@ int(-1)
--- testing: 0 >> 9223372036854775807 ---
int(0)
--- testing: 0 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> 2147483647 ---
int(0)
--- testing: 0 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> 9223372034707292160 ---
int(0)
--- testing: 0 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> 2147483648 ---
int(0)
--- testing: 0 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> 4294967294 ---
int(0)
--- testing: 0 >> 4294967295 ---
@@ -334,27 +342,27 @@ int(0)
--- testing: 0 >> 9223372036854775806 ---
int(0)
--- testing: 0 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 0 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> 9223372036854775807 ---
int(0)
--- testing: 1 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> 2147483647 ---
int(0)
--- testing: 1 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> 9223372034707292160 ---
int(0)
--- testing: 1 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> 2147483648 ---
int(0)
--- testing: 1 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> 4294967294 ---
int(0)
--- testing: 1 >> 4294967295 ---
@@ -364,27 +372,27 @@ int(0)
--- testing: 1 >> 9223372036854775806 ---
int(0)
--- testing: 1 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 1 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> 9223372036854775807 ---
int(-1)
--- testing: -1 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> 2147483647 ---
int(-1)
--- testing: -1 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> 9223372034707292160 ---
int(-1)
--- testing: -1 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> 2147483648 ---
int(-1)
--- testing: -1 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> 4294967294 ---
int(-1)
--- testing: -1 >> 4294967295 ---
@@ -394,27 +402,27 @@ int(-1)
--- testing: -1 >> 9223372036854775806 ---
int(-1)
--- testing: -1 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -1 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> 9223372036854775807 ---
int(0)
--- testing: 7 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> 2147483647 ---
int(0)
--- testing: 7 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> 9223372034707292160 ---
int(0)
--- testing: 7 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> 2147483648 ---
int(0)
--- testing: 7 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> 4294967294 ---
int(0)
--- testing: 7 >> 4294967295 ---
@@ -424,27 +432,27 @@ int(0)
--- testing: 7 >> 9223372036854775806 ---
int(0)
--- testing: 7 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 7 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> 9223372036854775807 ---
int(0)
--- testing: 9 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> 2147483647 ---
int(0)
--- testing: 9 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> 9223372034707292160 ---
int(0)
--- testing: 9 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> 2147483648 ---
int(0)
--- testing: 9 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> 4294967294 ---
int(0)
--- testing: 9 >> 4294967295 ---
@@ -454,27 +462,27 @@ int(0)
--- testing: 9 >> 9223372036854775806 ---
int(0)
--- testing: 9 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> 9223372036854775807 ---
int(0)
--- testing: 65 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> 2147483647 ---
int(0)
--- testing: 65 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> 9223372034707292160 ---
int(0)
--- testing: 65 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> 2147483648 ---
int(0)
--- testing: 65 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> 4294967294 ---
int(0)
--- testing: 65 >> 4294967295 ---
@@ -484,27 +492,27 @@ int(0)
--- testing: 65 >> 9223372036854775806 ---
int(0)
--- testing: 65 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 65 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> 9223372036854775807 ---
int(-1)
--- testing: -44 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> 2147483647 ---
int(-1)
--- testing: -44 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> 9223372034707292160 ---
int(-1)
--- testing: -44 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> 2147483648 ---
int(-1)
--- testing: -44 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> 4294967294 ---
int(-1)
--- testing: -44 >> 4294967295 ---
@@ -514,27 +522,27 @@ int(-1)
--- testing: -44 >> 9223372036854775806 ---
int(-1)
--- testing: -44 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: -44 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 9223372036854775807 ---
int(0)
--- testing: 2147483647 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 2147483647 ---
int(0)
--- testing: 2147483647 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 9223372034707292160 ---
int(0)
--- testing: 2147483647 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 2147483648 ---
int(0)
--- testing: 2147483647 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> 4294967294 ---
int(0)
--- testing: 2147483647 >> 4294967295 ---
@@ -544,27 +552,27 @@ int(0)
--- testing: 2147483647 >> 9223372036854775806 ---
int(0)
--- testing: 2147483647 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 2147483647 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 9223372036854775807 ---
int(0)
--- testing: 9223372036854775807 >> -9223372036854775808 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 2147483647 ---
int(0)
--- testing: 9223372036854775807 >> -2147483648 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 9223372034707292160 ---
int(0)
--- testing: 9223372036854775807 >> -9223372034707292160 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 2147483648 ---
int(0)
--- testing: 9223372036854775807 >> -2147483649 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> 4294967294 ---
int(0)
--- testing: 9223372036854775807 >> 4294967295 ---
@@ -574,9 +582,9 @@ int(0)
--- testing: 9223372036854775807 >> 9223372036854775806 ---
int(0)
--- testing: 9223372036854775807 >> 9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> -9223372036854775807 ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 9223372036854775807 >> -9.2233720368548E+18 ---
-bool(false)
+Exception: Bit shift by negative number
===DONE===
diff --git a/tests/lang/operators/bitwiseShiftRight_variationStr.phpt b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt
index 250c7791c2..018e9b27e5 100644
--- a/tests/lang/operators/bitwiseShiftRight_variationStr.phpt
+++ b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt
@@ -12,8 +12,12 @@ error_reporting(E_ERROR);
foreach ($strVals as $strVal) {
foreach($strVals as $otherVal) {
- echo "--- testing: '$strVal' >> '$otherVal' ---\n";
- var_dump($strVal>>$otherVal);
+ echo "--- testing: '$strVal' >> '$otherVal' ---\n";
+ try {
+ var_dump($strVal>>$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -26,11 +30,11 @@ int(0)
--- testing: '0' >> '65' ---
int(0)
--- testing: '0' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' >> '1.2' ---
int(0)
--- testing: '0' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '0' >> 'abc' ---
int(0)
--- testing: '0' >> '123abc' ---
@@ -54,11 +58,11 @@ int(65)
--- testing: '65' >> '65' ---
int(0)
--- testing: '65' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' >> '1.2' ---
int(32)
--- testing: '65' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '65' >> 'abc' ---
int(65)
--- testing: '65' >> '123abc' ---
@@ -82,11 +86,11 @@ int(-44)
--- testing: '-44' >> '65' ---
int(-1)
--- testing: '-44' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' >> '1.2' ---
int(-22)
--- testing: '-44' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-44' >> 'abc' ---
int(-44)
--- testing: '-44' >> '123abc' ---
@@ -110,11 +114,11 @@ int(1)
--- testing: '1.2' >> '65' ---
int(0)
--- testing: '1.2' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' >> '1.2' ---
int(0)
--- testing: '1.2' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '1.2' >> 'abc' ---
int(1)
--- testing: '1.2' >> '123abc' ---
@@ -138,11 +142,11 @@ int(-7)
--- testing: '-7.7' >> '65' ---
int(-1)
--- testing: '-7.7' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' >> '1.2' ---
int(-4)
--- testing: '-7.7' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '-7.7' >> 'abc' ---
int(-7)
--- testing: '-7.7' >> '123abc' ---
@@ -166,11 +170,11 @@ int(0)
--- testing: 'abc' >> '65' ---
int(0)
--- testing: 'abc' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' >> '1.2' ---
int(0)
--- testing: 'abc' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'abc' >> 'abc' ---
int(0)
--- testing: 'abc' >> '123abc' ---
@@ -194,11 +198,11 @@ int(123)
--- testing: '123abc' >> '65' ---
int(0)
--- testing: '123abc' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' >> '1.2' ---
int(61)
--- testing: '123abc' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc' >> 'abc' ---
int(123)
--- testing: '123abc' >> '123abc' ---
@@ -222,11 +226,11 @@ int(123)
--- testing: '123e5' >> '65' ---
int(0)
--- testing: '123e5' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' >> '1.2' ---
int(61)
--- testing: '123e5' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5' >> 'abc' ---
int(123)
--- testing: '123e5' >> '123abc' ---
@@ -250,11 +254,11 @@ int(123)
--- testing: '123e5xyz' >> '65' ---
int(0)
--- testing: '123e5xyz' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' >> '1.2' ---
int(61)
--- testing: '123e5xyz' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123e5xyz' >> 'abc' ---
int(123)
--- testing: '123e5xyz' >> '123abc' ---
@@ -278,11 +282,11 @@ int(123)
--- testing: ' 123abc' >> '65' ---
int(0)
--- testing: ' 123abc' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' >> '1.2' ---
int(61)
--- testing: ' 123abc' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: ' 123abc' >> 'abc' ---
int(123)
--- testing: ' 123abc' >> '123abc' ---
@@ -306,11 +310,11 @@ int(123)
--- testing: '123 abc' >> '65' ---
int(0)
--- testing: '123 abc' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' >> '1.2' ---
int(61)
--- testing: '123 abc' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123 abc' >> 'abc' ---
int(123)
--- testing: '123 abc' >> '123abc' ---
@@ -334,11 +338,11 @@ int(123)
--- testing: '123abc ' >> '65' ---
int(0)
--- testing: '123abc ' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' >> '1.2' ---
int(61)
--- testing: '123abc ' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '123abc ' >> 'abc' ---
int(123)
--- testing: '123abc ' >> '123abc' ---
@@ -362,11 +366,11 @@ int(3)
--- testing: '3.4a' >> '65' ---
int(0)
--- testing: '3.4a' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' >> '1.2' ---
int(1)
--- testing: '3.4a' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: '3.4a' >> 'abc' ---
int(3)
--- testing: '3.4a' >> '123abc' ---
@@ -390,11 +394,11 @@ int(0)
--- testing: 'a5.9' >> '65' ---
int(0)
--- testing: 'a5.9' >> '-44' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' >> '1.2' ---
int(0)
--- testing: 'a5.9' >> '-7.7' ---
-bool(false)
+Exception: Bit shift by negative number
--- testing: 'a5.9' >> 'abc' ---
int(0)
--- testing: 'a5.9' >> '123abc' ---
diff --git a/tests/lang/operators/divide_basiclong_64bit.phpt b/tests/lang/operators/divide_basiclong_64bit.phpt
index b5d6df9bba..c6bed0c88b 100644
--- a/tests/lang/operators/divide_basiclong_64bit.phpt
+++ b/tests/lang/operators/divide_basiclong_64bit.phpt
@@ -40,7 +40,7 @@ foreach ($otherVals as $otherVal) {
===DONE===
--EXPECT--
--- testing: 9223372036854775807 / 0 ---
-bool(false)
+float(INF)
--- testing: 9223372036854775807 / 1 ---
int(9223372036854775807)
--- testing: 9223372036854775807 / -1 ---
@@ -58,7 +58,7 @@ float(4294967298)
--- testing: 9223372036854775807 / 9223372036854775807 ---
int(1)
--- testing: -9223372036854775808 / 0 ---
-bool(false)
+float(-INF)
--- testing: -9223372036854775808 / 1 ---
int(-9223372036854775808)
--- testing: -9223372036854775808 / -1 ---
@@ -76,7 +76,7 @@ float(-4294967298)
--- testing: -9223372036854775808 / 9223372036854775807 ---
float(-1)
--- testing: 2147483647 / 0 ---
-bool(false)
+float(INF)
--- testing: 2147483647 / 1 ---
int(2147483647)
--- testing: 2147483647 / -1 ---
@@ -94,7 +94,7 @@ int(1)
--- testing: 2147483647 / 9223372036854775807 ---
float(2.3283064354545E-10)
--- testing: -2147483648 / 0 ---
-bool(false)
+float(-INF)
--- testing: -2147483648 / 1 ---
int(-2147483648)
--- testing: -2147483648 / -1 ---
@@ -112,7 +112,7 @@ float(-1.0000000004657)
--- testing: -2147483648 / 9223372036854775807 ---
float(-2.3283064365387E-10)
--- testing: 9223372034707292160 / 0 ---
-bool(false)
+float(INF)
--- testing: 9223372034707292160 / 1 ---
int(9223372034707292160)
--- testing: 9223372034707292160 / -1 ---
@@ -130,7 +130,7 @@ float(4294967297)
--- testing: 9223372034707292160 / 9223372036854775807 ---
float(0.99999999976717)
--- testing: -9223372034707292160 / 0 ---
-bool(false)
+float(-INF)
--- testing: -9223372034707292160 / 1 ---
int(-9223372034707292160)
--- testing: -9223372034707292160 / -1 ---
@@ -148,7 +148,7 @@ float(-4294967297)
--- testing: -9223372034707292160 / 9223372036854775807 ---
float(-0.99999999976717)
--- testing: 2147483648 / 0 ---
-bool(false)
+float(INF)
--- testing: 2147483648 / 1 ---
int(2147483648)
--- testing: 2147483648 / -1 ---
@@ -166,7 +166,7 @@ float(1.0000000004657)
--- testing: 2147483648 / 9223372036854775807 ---
float(2.3283064365387E-10)
--- testing: -2147483649 / 0 ---
-bool(false)
+float(-INF)
--- testing: -2147483649 / 1 ---
int(-2147483649)
--- testing: -2147483649 / -1 ---
@@ -184,7 +184,7 @@ float(-1.0000000009313)
--- testing: -2147483649 / 9223372036854775807 ---
float(-2.3283064376229E-10)
--- testing: 4294967294 / 0 ---
-bool(false)
+float(INF)
--- testing: 4294967294 / 1 ---
int(4294967294)
--- testing: 4294967294 / -1 ---
@@ -202,7 +202,7 @@ int(2)
--- testing: 4294967294 / 9223372036854775807 ---
float(4.656612870909E-10)
--- testing: 4294967295 / 0 ---
-bool(false)
+float(INF)
--- testing: 4294967295 / 1 ---
int(4294967295)
--- testing: 4294967295 / -1 ---
@@ -220,7 +220,7 @@ float(2.0000000004657)
--- testing: 4294967295 / 9223372036854775807 ---
float(4.6566128719932E-10)
--- testing: 4294967293 / 0 ---
-bool(false)
+float(INF)
--- testing: 4294967293 / 1 ---
int(4294967293)
--- testing: 4294967293 / -1 ---
@@ -238,7 +238,7 @@ float(1.9999999995343)
--- testing: 4294967293 / 9223372036854775807 ---
float(4.6566128698248E-10)
--- testing: 9223372036854775806 / 0 ---
-bool(false)
+float(INF)
--- testing: 9223372036854775806 / 1 ---
int(9223372036854775806)
--- testing: 9223372036854775806 / -1 ---
@@ -256,7 +256,7 @@ int(4294967298)
--- testing: 9223372036854775806 / 9223372036854775807 ---
float(1)
--- testing: 9.2233720368548E+18 / 0 ---
-bool(false)
+float(INF)
--- testing: 9.2233720368548E+18 / 1 ---
float(9.2233720368548E+18)
--- testing: 9.2233720368548E+18 / -1 ---
@@ -274,7 +274,7 @@ float(4294967298)
--- testing: 9.2233720368548E+18 / 9223372036854775807 ---
float(1)
--- testing: -9223372036854775807 / 0 ---
-bool(false)
+float(-INF)
--- testing: -9223372036854775807 / 1 ---
int(-9223372036854775807)
--- testing: -9223372036854775807 / -1 ---
@@ -292,7 +292,7 @@ float(-4294967298)
--- testing: -9223372036854775807 / 9223372036854775807 ---
int(-1)
--- testing: -9.2233720368548E+18 / 0 ---
-bool(false)
+float(-INF)
--- testing: -9.2233720368548E+18 / 1 ---
float(-9.2233720368548E+18)
--- testing: -9.2233720368548E+18 / -1 ---
diff --git a/tests/lang/operators/divide_variationStr.phpt b/tests/lang/operators/divide_variationStr.phpt
index e48e9e1750..08250db28f 100644
--- a/tests/lang/operators/divide_variationStr.phpt
+++ b/tests/lang/operators/divide_variationStr.phpt
@@ -22,7 +22,7 @@ foreach ($strVals as $strVal) {
===DONE===
--EXPECT--
--- testing: '0' / '0' ---
-bool(false)
+float(INF)
--- testing: '0' / '65' ---
int(0)
--- testing: '0' / '-44' ---
@@ -32,7 +32,7 @@ float(0)
--- testing: '0' / '-7.7' ---
float(-0)
--- testing: '0' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '0' / '123abc' ---
int(0)
--- testing: '0' / '123e5' ---
@@ -48,9 +48,9 @@ int(0)
--- testing: '0' / '3.4a' ---
float(0)
--- testing: '0' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '65' / '0' ---
-bool(false)
+float(INF)
--- testing: '65' / '65' ---
int(1)
--- testing: '65' / '-44' ---
@@ -60,7 +60,7 @@ float(54.166666666667)
--- testing: '65' / '-7.7' ---
float(-8.4415584415584)
--- testing: '65' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '65' / '123abc' ---
float(0.52845528455285)
--- testing: '65' / '123e5' ---
@@ -76,9 +76,9 @@ float(0.52845528455285)
--- testing: '65' / '3.4a' ---
float(19.117647058824)
--- testing: '65' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '-44' / '0' ---
-bool(false)
+float(-INF)
--- testing: '-44' / '65' ---
float(-0.67692307692308)
--- testing: '-44' / '-44' ---
@@ -88,7 +88,7 @@ float(-36.666666666667)
--- testing: '-44' / '-7.7' ---
float(5.7142857142857)
--- testing: '-44' / 'abc' ---
-bool(false)
+float(-INF)
--- testing: '-44' / '123abc' ---
float(-0.35772357723577)
--- testing: '-44' / '123e5' ---
@@ -104,9 +104,9 @@ float(-0.35772357723577)
--- testing: '-44' / '3.4a' ---
float(-12.941176470588)
--- testing: '-44' / 'a5.9' ---
-bool(false)
+float(-INF)
--- testing: '1.2' / '0' ---
-bool(false)
+float(INF)
--- testing: '1.2' / '65' ---
float(0.018461538461538)
--- testing: '1.2' / '-44' ---
@@ -116,7 +116,7 @@ float(1)
--- testing: '1.2' / '-7.7' ---
float(-0.15584415584416)
--- testing: '1.2' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '1.2' / '123abc' ---
float(0.0097560975609756)
--- testing: '1.2' / '123e5' ---
@@ -132,9 +132,9 @@ float(0.0097560975609756)
--- testing: '1.2' / '3.4a' ---
float(0.35294117647059)
--- testing: '1.2' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '-7.7' / '0' ---
-bool(false)
+float(-INF)
--- testing: '-7.7' / '65' ---
float(-0.11846153846154)
--- testing: '-7.7' / '-44' ---
@@ -144,7 +144,7 @@ float(-6.4166666666667)
--- testing: '-7.7' / '-7.7' ---
float(1)
--- testing: '-7.7' / 'abc' ---
-bool(false)
+float(-INF)
--- testing: '-7.7' / '123abc' ---
float(-0.06260162601626)
--- testing: '-7.7' / '123e5' ---
@@ -160,9 +160,9 @@ float(-0.06260162601626)
--- testing: '-7.7' / '3.4a' ---
float(-2.2647058823529)
--- testing: '-7.7' / 'a5.9' ---
-bool(false)
+float(-INF)
--- testing: 'abc' / '0' ---
-bool(false)
+float(INF)
--- testing: 'abc' / '65' ---
int(0)
--- testing: 'abc' / '-44' ---
@@ -172,7 +172,7 @@ float(0)
--- testing: 'abc' / '-7.7' ---
float(-0)
--- testing: 'abc' / 'abc' ---
-bool(false)
+float(INF)
--- testing: 'abc' / '123abc' ---
int(0)
--- testing: 'abc' / '123e5' ---
@@ -188,9 +188,9 @@ int(0)
--- testing: 'abc' / '3.4a' ---
float(0)
--- testing: 'abc' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '123abc' / '0' ---
-bool(false)
+float(INF)
--- testing: '123abc' / '65' ---
float(1.8923076923077)
--- testing: '123abc' / '-44' ---
@@ -200,7 +200,7 @@ float(102.5)
--- testing: '123abc' / '-7.7' ---
float(-15.974025974026)
--- testing: '123abc' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '123abc' / '123abc' ---
int(1)
--- testing: '123abc' / '123e5' ---
@@ -216,9 +216,9 @@ int(1)
--- testing: '123abc' / '3.4a' ---
float(36.176470588235)
--- testing: '123abc' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '123e5' / '0' ---
-bool(false)
+float(INF)
--- testing: '123e5' / '65' ---
float(189230.76923077)
--- testing: '123e5' / '-44' ---
@@ -228,7 +228,7 @@ float(10250000)
--- testing: '123e5' / '-7.7' ---
float(-1597402.5974026)
--- testing: '123e5' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '123e5' / '123abc' ---
float(100000)
--- testing: '123e5' / '123e5' ---
@@ -244,9 +244,9 @@ float(100000)
--- testing: '123e5' / '3.4a' ---
float(3617647.0588235)
--- testing: '123e5' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '123e5xyz' / '0' ---
-bool(false)
+float(INF)
--- testing: '123e5xyz' / '65' ---
float(189230.76923077)
--- testing: '123e5xyz' / '-44' ---
@@ -256,7 +256,7 @@ float(10250000)
--- testing: '123e5xyz' / '-7.7' ---
float(-1597402.5974026)
--- testing: '123e5xyz' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '123e5xyz' / '123abc' ---
float(100000)
--- testing: '123e5xyz' / '123e5' ---
@@ -272,9 +272,9 @@ float(100000)
--- testing: '123e5xyz' / '3.4a' ---
float(3617647.0588235)
--- testing: '123e5xyz' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: ' 123abc' / '0' ---
-bool(false)
+float(INF)
--- testing: ' 123abc' / '65' ---
float(1.8923076923077)
--- testing: ' 123abc' / '-44' ---
@@ -284,7 +284,7 @@ float(102.5)
--- testing: ' 123abc' / '-7.7' ---
float(-15.974025974026)
--- testing: ' 123abc' / 'abc' ---
-bool(false)
+float(INF)
--- testing: ' 123abc' / '123abc' ---
int(1)
--- testing: ' 123abc' / '123e5' ---
@@ -300,9 +300,9 @@ int(1)
--- testing: ' 123abc' / '3.4a' ---
float(36.176470588235)
--- testing: ' 123abc' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '123 abc' / '0' ---
-bool(false)
+float(INF)
--- testing: '123 abc' / '65' ---
float(1.8923076923077)
--- testing: '123 abc' / '-44' ---
@@ -312,7 +312,7 @@ float(102.5)
--- testing: '123 abc' / '-7.7' ---
float(-15.974025974026)
--- testing: '123 abc' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '123 abc' / '123abc' ---
int(1)
--- testing: '123 abc' / '123e5' ---
@@ -328,9 +328,9 @@ int(1)
--- testing: '123 abc' / '3.4a' ---
float(36.176470588235)
--- testing: '123 abc' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '123abc ' / '0' ---
-bool(false)
+float(INF)
--- testing: '123abc ' / '65' ---
float(1.8923076923077)
--- testing: '123abc ' / '-44' ---
@@ -340,7 +340,7 @@ float(102.5)
--- testing: '123abc ' / '-7.7' ---
float(-15.974025974026)
--- testing: '123abc ' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '123abc ' / '123abc' ---
int(1)
--- testing: '123abc ' / '123e5' ---
@@ -356,9 +356,9 @@ int(1)
--- testing: '123abc ' / '3.4a' ---
float(36.176470588235)
--- testing: '123abc ' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: '3.4a' / '0' ---
-bool(false)
+float(INF)
--- testing: '3.4a' / '65' ---
float(0.052307692307692)
--- testing: '3.4a' / '-44' ---
@@ -368,7 +368,7 @@ float(2.8333333333333)
--- testing: '3.4a' / '-7.7' ---
float(-0.44155844155844)
--- testing: '3.4a' / 'abc' ---
-bool(false)
+float(INF)
--- testing: '3.4a' / '123abc' ---
float(0.027642276422764)
--- testing: '3.4a' / '123e5' ---
@@ -384,9 +384,9 @@ float(0.027642276422764)
--- testing: '3.4a' / '3.4a' ---
float(1)
--- testing: '3.4a' / 'a5.9' ---
-bool(false)
+float(INF)
--- testing: 'a5.9' / '0' ---
-bool(false)
+float(INF)
--- testing: 'a5.9' / '65' ---
int(0)
--- testing: 'a5.9' / '-44' ---
@@ -396,7 +396,7 @@ float(0)
--- testing: 'a5.9' / '-7.7' ---
float(-0)
--- testing: 'a5.9' / 'abc' ---
-bool(false)
+float(INF)
--- testing: 'a5.9' / '123abc' ---
int(0)
--- testing: 'a5.9' / '123e5' ---
@@ -412,5 +412,5 @@ int(0)
--- testing: 'a5.9' / '3.4a' ---
float(0)
--- testing: 'a5.9' / 'a5.9' ---
-bool(false)
+float(INF)
===DONE===
diff --git a/tests/lang/operators/modulus_basiclong_64bit.phpt b/tests/lang/operators/modulus_basiclong_64bit.phpt
index 3315f02c5b..3fef77d85c 100644
--- a/tests/lang/operators/modulus_basiclong_64bit.phpt
+++ b/tests/lang/operators/modulus_basiclong_64bit.phpt
@@ -24,15 +24,23 @@ error_reporting(E_ERROR);
foreach ($longVals as $longVal) {
foreach($otherVals as $otherVal) {
- echo "--- testing: $longVal % $otherVal ---\n";
- var_dump($longVal%$otherVal);
+ echo "--- testing: $longVal % $otherVal ---\n";
+ try {
+ var_dump($longVal%$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
foreach ($otherVals as $otherVal) {
foreach($longVals as $longVal) {
- echo "--- testing: $otherVal % $longVal ---\n";
- var_dump($otherVal%$longVal);
+ echo "--- testing: $otherVal % $longVal ---\n";
+ try {
+ var_dump($otherVal%$longVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -40,7 +48,7 @@ foreach ($otherVals as $otherVal) {
===DONE===
--EXPECT--
--- testing: 9223372036854775807 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 9223372036854775807 % 1 ---
int(0)
--- testing: 9223372036854775807 % -1 ---
@@ -58,7 +66,7 @@ int(1)
--- testing: 9223372036854775807 % 9223372036854775807 ---
int(0)
--- testing: -9223372036854775808 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -9223372036854775808 % 1 ---
int(0)
--- testing: -9223372036854775808 % -1 ---
@@ -76,7 +84,7 @@ int(-2)
--- testing: -9223372036854775808 % 9223372036854775807 ---
int(-1)
--- testing: 2147483647 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 2147483647 % 1 ---
int(0)
--- testing: 2147483647 % -1 ---
@@ -94,7 +102,7 @@ int(0)
--- testing: 2147483647 % 9223372036854775807 ---
int(2147483647)
--- testing: -2147483648 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -2147483648 % 1 ---
int(0)
--- testing: -2147483648 % -1 ---
@@ -112,7 +120,7 @@ int(-1)
--- testing: -2147483648 % 9223372036854775807 ---
int(-2147483648)
--- testing: 9223372034707292160 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 9223372034707292160 % 1 ---
int(0)
--- testing: 9223372034707292160 % -1 ---
@@ -130,7 +138,7 @@ int(1)
--- testing: 9223372034707292160 % 9223372036854775807 ---
int(9223372034707292160)
--- testing: -9223372034707292160 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -9223372034707292160 % 1 ---
int(0)
--- testing: -9223372034707292160 % -1 ---
@@ -148,7 +156,7 @@ int(-1)
--- testing: -9223372034707292160 % 9223372036854775807 ---
int(-9223372034707292160)
--- testing: 2147483648 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 2147483648 % 1 ---
int(0)
--- testing: 2147483648 % -1 ---
@@ -166,7 +174,7 @@ int(1)
--- testing: 2147483648 % 9223372036854775807 ---
int(2147483648)
--- testing: -2147483649 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -2147483649 % 1 ---
int(0)
--- testing: -2147483649 % -1 ---
@@ -184,7 +192,7 @@ int(-2)
--- testing: -2147483649 % 9223372036854775807 ---
int(-2147483649)
--- testing: 4294967294 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 4294967294 % 1 ---
int(0)
--- testing: 4294967294 % -1 ---
@@ -202,7 +210,7 @@ int(0)
--- testing: 4294967294 % 9223372036854775807 ---
int(4294967294)
--- testing: 4294967295 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 4294967295 % 1 ---
int(0)
--- testing: 4294967295 % -1 ---
@@ -220,7 +228,7 @@ int(1)
--- testing: 4294967295 % 9223372036854775807 ---
int(4294967295)
--- testing: 4294967293 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 4294967293 % 1 ---
int(0)
--- testing: 4294967293 % -1 ---
@@ -238,7 +246,7 @@ int(2147483646)
--- testing: 4294967293 % 9223372036854775807 ---
int(4294967293)
--- testing: 9223372036854775806 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 9223372036854775806 % 1 ---
int(0)
--- testing: 9223372036854775806 % -1 ---
@@ -256,7 +264,7 @@ int(0)
--- testing: 9223372036854775806 % 9223372036854775807 ---
int(9223372036854775806)
--- testing: 9.2233720368548E+18 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: 9.2233720368548E+18 % 1 ---
int(0)
--- testing: 9.2233720368548E+18 % -1 ---
@@ -274,7 +282,7 @@ int(-2)
--- testing: 9.2233720368548E+18 % 9223372036854775807 ---
int(-1)
--- testing: -9223372036854775807 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -9223372036854775807 % 1 ---
int(0)
--- testing: -9223372036854775807 % -1 ---
@@ -292,7 +300,7 @@ int(-1)
--- testing: -9223372036854775807 % 9223372036854775807 ---
int(0)
--- testing: -9.2233720368548E+18 % 0 ---
-bool(false)
+Exception: Division by zero
--- testing: -9.2233720368548E+18 % 1 ---
int(0)
--- testing: -9.2233720368548E+18 % -1 ---
diff --git a/tests/lang/operators/modulus_variationStr.phpt b/tests/lang/operators/modulus_variationStr.phpt
index 7b3ce7679a..24312b5611 100644
--- a/tests/lang/operators/modulus_variationStr.phpt
+++ b/tests/lang/operators/modulus_variationStr.phpt
@@ -12,8 +12,12 @@ error_reporting(E_ERROR);
foreach ($strVals as $strVal) {
foreach($strVals as $otherVal) {
- echo "--- testing: '$strVal' % '$otherVal' ---\n";
- var_dump($strVal%$otherVal);
+ echo "--- testing: '$strVal' % '$otherVal' ---\n";
+ try {
+ var_dump($strVal%$otherVal);
+ } catch (Exception $e) {
+ echo "Exception: " . $e->getMessage() . "\n";
+ }
}
}
@@ -22,7 +26,7 @@ foreach ($strVals as $strVal) {
===DONE===
--EXPECT--
--- testing: '0' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '0' % '65' ---
int(0)
--- testing: '0' % '-44' ---
@@ -32,7 +36,7 @@ int(0)
--- testing: '0' % '-7.7' ---
int(0)
--- testing: '0' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '0' % '123abc' ---
int(0)
--- testing: '0' % '123e5' ---
@@ -48,9 +52,9 @@ int(0)
--- testing: '0' % '3.4a' ---
int(0)
--- testing: '0' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '65' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '65' % '65' ---
int(0)
--- testing: '65' % '-44' ---
@@ -60,7 +64,7 @@ int(0)
--- testing: '65' % '-7.7' ---
int(2)
--- testing: '65' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '65' % '123abc' ---
int(65)
--- testing: '65' % '123e5' ---
@@ -76,9 +80,9 @@ int(65)
--- testing: '65' % '3.4a' ---
int(2)
--- testing: '65' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '-44' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '-44' % '65' ---
int(-44)
--- testing: '-44' % '-44' ---
@@ -88,7 +92,7 @@ int(0)
--- testing: '-44' % '-7.7' ---
int(-2)
--- testing: '-44' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '-44' % '123abc' ---
int(-44)
--- testing: '-44' % '123e5' ---
@@ -104,9 +108,9 @@ int(-44)
--- testing: '-44' % '3.4a' ---
int(-2)
--- testing: '-44' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '1.2' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '1.2' % '65' ---
int(1)
--- testing: '1.2' % '-44' ---
@@ -116,7 +120,7 @@ int(0)
--- testing: '1.2' % '-7.7' ---
int(1)
--- testing: '1.2' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '1.2' % '123abc' ---
int(1)
--- testing: '1.2' % '123e5' ---
@@ -132,9 +136,9 @@ int(1)
--- testing: '1.2' % '3.4a' ---
int(1)
--- testing: '1.2' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '-7.7' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '-7.7' % '65' ---
int(-7)
--- testing: '-7.7' % '-44' ---
@@ -144,7 +148,7 @@ int(0)
--- testing: '-7.7' % '-7.7' ---
int(0)
--- testing: '-7.7' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '-7.7' % '123abc' ---
int(-7)
--- testing: '-7.7' % '123e5' ---
@@ -160,9 +164,9 @@ int(-7)
--- testing: '-7.7' % '3.4a' ---
int(-1)
--- testing: '-7.7' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: 'abc' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: 'abc' % '65' ---
int(0)
--- testing: 'abc' % '-44' ---
@@ -172,7 +176,7 @@ int(0)
--- testing: 'abc' % '-7.7' ---
int(0)
--- testing: 'abc' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: 'abc' % '123abc' ---
int(0)
--- testing: 'abc' % '123e5' ---
@@ -188,9 +192,9 @@ int(0)
--- testing: 'abc' % '3.4a' ---
int(0)
--- testing: 'abc' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc' % '65' ---
int(58)
--- testing: '123abc' % '-44' ---
@@ -200,7 +204,7 @@ int(0)
--- testing: '123abc' % '-7.7' ---
int(4)
--- testing: '123abc' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc' % '123abc' ---
int(0)
--- testing: '123abc' % '123e5' ---
@@ -216,9 +220,9 @@ int(0)
--- testing: '123abc' % '3.4a' ---
int(0)
--- testing: '123abc' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5' % '65' ---
int(58)
--- testing: '123e5' % '-44' ---
@@ -228,7 +232,7 @@ int(0)
--- testing: '123e5' % '-7.7' ---
int(4)
--- testing: '123e5' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5' % '123abc' ---
int(0)
--- testing: '123e5' % '123e5' ---
@@ -244,9 +248,9 @@ int(0)
--- testing: '123e5' % '3.4a' ---
int(0)
--- testing: '123e5' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5xyz' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5xyz' % '65' ---
int(58)
--- testing: '123e5xyz' % '-44' ---
@@ -256,7 +260,7 @@ int(0)
--- testing: '123e5xyz' % '-7.7' ---
int(4)
--- testing: '123e5xyz' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '123e5xyz' % '123abc' ---
int(0)
--- testing: '123e5xyz' % '123e5' ---
@@ -272,9 +276,9 @@ int(0)
--- testing: '123e5xyz' % '3.4a' ---
int(0)
--- testing: '123e5xyz' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: ' 123abc' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: ' 123abc' % '65' ---
int(58)
--- testing: ' 123abc' % '-44' ---
@@ -284,7 +288,7 @@ int(0)
--- testing: ' 123abc' % '-7.7' ---
int(4)
--- testing: ' 123abc' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: ' 123abc' % '123abc' ---
int(0)
--- testing: ' 123abc' % '123e5' ---
@@ -300,9 +304,9 @@ int(0)
--- testing: ' 123abc' % '3.4a' ---
int(0)
--- testing: ' 123abc' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '123 abc' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '123 abc' % '65' ---
int(58)
--- testing: '123 abc' % '-44' ---
@@ -312,7 +316,7 @@ int(0)
--- testing: '123 abc' % '-7.7' ---
int(4)
--- testing: '123 abc' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '123 abc' % '123abc' ---
int(0)
--- testing: '123 abc' % '123e5' ---
@@ -328,9 +332,9 @@ int(0)
--- testing: '123 abc' % '3.4a' ---
int(0)
--- testing: '123 abc' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc ' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc ' % '65' ---
int(58)
--- testing: '123abc ' % '-44' ---
@@ -340,7 +344,7 @@ int(0)
--- testing: '123abc ' % '-7.7' ---
int(4)
--- testing: '123abc ' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '123abc ' % '123abc' ---
int(0)
--- testing: '123abc ' % '123e5' ---
@@ -356,9 +360,9 @@ int(0)
--- testing: '123abc ' % '3.4a' ---
int(0)
--- testing: '123abc ' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: '3.4a' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: '3.4a' % '65' ---
int(3)
--- testing: '3.4a' % '-44' ---
@@ -368,7 +372,7 @@ int(0)
--- testing: '3.4a' % '-7.7' ---
int(3)
--- testing: '3.4a' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: '3.4a' % '123abc' ---
int(3)
--- testing: '3.4a' % '123e5' ---
@@ -384,9 +388,9 @@ int(3)
--- testing: '3.4a' % '3.4a' ---
int(0)
--- testing: '3.4a' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
--- testing: 'a5.9' % '0' ---
-bool(false)
+Exception: Division by zero
--- testing: 'a5.9' % '65' ---
int(0)
--- testing: 'a5.9' % '-44' ---
@@ -396,7 +400,7 @@ int(0)
--- testing: 'a5.9' % '-7.7' ---
int(0)
--- testing: 'a5.9' % 'abc' ---
-bool(false)
+Exception: Division by zero
--- testing: 'a5.9' % '123abc' ---
int(0)
--- testing: 'a5.9' % '123e5' ---
@@ -412,5 +416,5 @@ int(0)
--- testing: 'a5.9' % '3.4a' ---
int(0)
--- testing: 'a5.9' % 'a5.9' ---
-bool(false)
+Exception: Division by zero
===DONE===