summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRobert Nicholson <nicholsr@php.net>2009-06-08 11:59:32 +0000
committerRobert Nicholson <nicholsr@php.net>2009-06-08 11:59:32 +0000
commite592b4fd158037d32a610d32060e4c01b18059ac (patch)
tree281555cde6a2b5622ac9a1d8fba05cb718fc3f13 /tests
parentec777b89f48ac998ebc3516290cf2f2e043d92e8 (diff)
downloadphp-git-e592b4fd158037d32a610d32060e4c01b18059ac.tar.gz
New tests for operators. These tests were auto generated to verify correctness for a number of significant values. The work was done by Dave Kelsey.
Diffstat (limited to 'tests')
-rw-r--r--tests/lang/operators/add_basiclong_64bit.phpt582
-rw-r--r--tests/lang/operators/add_variationStr.phpt416
-rw-r--r--tests/lang/operators/bitwiseAnd_variationStr.phpt416
-rw-r--r--tests/lang/operators/bitwiseNot_variationStr.phpt48
-rw-r--r--tests/lang/operators/bitwiseOr_variationStr.phpt416
-rw-r--r--tests/lang/operators/bitwiseShiftLeft_variationStr.phpt421
-rw-r--r--tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt420
-rw-r--r--tests/lang/operators/bitwiseShiftRight_variationStr.phpt416
-rw-r--r--tests/lang/operators/bitwiseXor_variationStr.phpt416
-rw-r--r--tests/lang/operators/divide_basiclong_64bit.phpt582
-rw-r--r--tests/lang/operators/divide_variationStr.phpt416
-rw-r--r--tests/lang/operators/modulus_variationStr.phpt416
-rw-r--r--tests/lang/operators/multiply_basiclong_64bit.phpt582
-rw-r--r--tests/lang/operators/multiply_variationStr.phpt416
-rw-r--r--tests/lang/operators/negate_basiclong_64bit.phpt60
-rw-r--r--tests/lang/operators/negate_variationStr.phpt48
-rw-r--r--tests/lang/operators/operator_equals_basic.phpt65
-rw-r--r--tests/lang/operators/operator_equals_variation.phpt63
-rw-r--r--tests/lang/operators/operator_equals_variation_64bit.phpt65
-rw-r--r--tests/lang/operators/operator_gt_basic.phpt65
-rw-r--r--tests/lang/operators/operator_gt_or_equal_basic.phpt65
-rw-r--r--tests/lang/operators/operator_gt_or_equal_variation.phpt63
-rw-r--r--tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt63
-rw-r--r--tests/lang/operators/operator_gt_variation.phpt62
-rw-r--r--tests/lang/operators/operator_gt_variation_64bit.phpt62
-rw-r--r--tests/lang/operators/operator_identical_basic.phpt65
-rw-r--r--tests/lang/operators/operator_identical_variation.phpt63
-rw-r--r--tests/lang/operators/operator_identical_variation_64bit.phpt65
-rw-r--r--tests/lang/operators/operator_lt_basic.phpt62
-rw-r--r--tests/lang/operators/operator_lt_or_equal_basic.phpt64
-rw-r--r--tests/lang/operators/operator_lt_or_equal_variation.phpt63
-rw-r--r--tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt63
-rw-r--r--tests/lang/operators/operator_lt_variation.phpt60
-rw-r--r--tests/lang/operators/operator_lt_variation_64bit.phpt60
-rw-r--r--tests/lang/operators/operator_notequals_basic.phpt65
-rw-r--r--tests/lang/operators/operator_notequals_variation.phpt63
-rw-r--r--tests/lang/operators/operator_notequals_variation_64bit.phpt65
-rw-r--r--tests/lang/operators/operator_notidentical_basic.phpt65
-rw-r--r--tests/lang/operators/operator_notidentical_variation.phpt64
-rw-r--r--tests/lang/operators/operator_notidentical_variation_64bit.phpt65
-rw-r--r--tests/lang/operators/postdec_basiclong_64bit.phpt61
-rw-r--r--tests/lang/operators/postdec_variationStr.phpt49
-rw-r--r--tests/lang/operators/postinc_basiclong_64bit.phpt61
-rw-r--r--tests/lang/operators/postinc_variationStr.phpt49
-rw-r--r--tests/lang/operators/predec_basiclong_64bit.phpt60
-rw-r--r--tests/lang/operators/predec_variationStr.phpt48
-rw-r--r--tests/lang/operators/preinc_basiclong_64bit.phpt60
-rw-r--r--tests/lang/operators/preinc_variationStr.phpt48
-rw-r--r--tests/lang/operators/subtract_basiclong_64bit.phpt582
-rw-r--r--tests/lang/operators/subtract_variationStr.phpt416
50 files changed, 9030 insertions, 0 deletions
diff --git a/tests/lang/operators/add_basiclong_64bit.phpt b/tests/lang/operators/add_basiclong_64bit.phpt
new file mode 100644
index 0000000000..cae8f4f1fb
--- /dev/null
+++ b/tests/lang/operators/add_basiclong_64bit.phpt
@@ -0,0 +1,582 @@
+--TEST--
+Test + operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
+
+error_reporting(E_ERROR);
+
+foreach ($longVals as $longVal) {
+ foreach($otherVals as $otherVal) {
+ echo "--- testing: $longVal + $otherVal ---\n";
+ var_dump($longVal+$otherVal);
+ }
+}
+
+foreach ($otherVals as $otherVal) {
+ foreach($longVals as $longVal) {
+ echo "--- testing: $otherVal + $longVal ---\n";
+ var_dump($otherVal+$longVal);
+ }
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 + 0 ---
+int(9223372036854775807)
+--- testing: 9223372036854775807 + 1 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 + -1 ---
+int(9223372036854775806)
+--- testing: 9223372036854775807 + 7 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 + 9 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 + 65 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 + -44 ---
+int(9223372036854775763)
+--- testing: 9223372036854775807 + 2147483647 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 + 9223372036854775807 ---
+float(1.844674407371E+19)
+--- testing: -9223372036854775808 + 0 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775808 + 1 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775808 + -1 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 + 7 ---
+int(-9223372036854775801)
+--- testing: -9223372036854775808 + 9 ---
+int(-9223372036854775799)
+--- testing: -9223372036854775808 + 65 ---
+int(-9223372036854775743)
+--- testing: -9223372036854775808 + -44 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 + 2147483647 ---
+int(-9223372034707292161)
+--- testing: -9223372036854775808 + 9223372036854775807 ---
+int(-1)
+--- testing: 2147483647 + 0 ---
+int(2147483647)
+--- testing: 2147483647 + 1 ---
+int(2147483648)
+--- testing: 2147483647 + -1 ---
+int(2147483646)
+--- testing: 2147483647 + 7 ---
+int(2147483654)
+--- testing: 2147483647 + 9 ---
+int(2147483656)
+--- testing: 2147483647 + 65 ---
+int(2147483712)
+--- testing: 2147483647 + -44 ---
+int(2147483603)
+--- testing: 2147483647 + 2147483647 ---
+int(4294967294)
+--- testing: 2147483647 + 9223372036854775807 ---
+float(9.2233720390023E+18)
+--- testing: -2147483648 + 0 ---
+int(-2147483648)
+--- testing: -2147483648 + 1 ---
+int(-2147483647)
+--- testing: -2147483648 + -1 ---
+int(-2147483649)
+--- testing: -2147483648 + 7 ---
+int(-2147483641)
+--- testing: -2147483648 + 9 ---
+int(-2147483639)
+--- testing: -2147483648 + 65 ---
+int(-2147483583)
+--- testing: -2147483648 + -44 ---
+int(-2147483692)
+--- testing: -2147483648 + 2147483647 ---
+int(-1)
+--- testing: -2147483648 + 9223372036854775807 ---
+int(9223372034707292159)
+--- testing: 9223372034707292160 + 0 ---
+int(9223372034707292160)
+--- testing: 9223372034707292160 + 1 ---
+int(9223372034707292161)
+--- testing: 9223372034707292160 + -1 ---
+int(9223372034707292159)
+--- testing: 9223372034707292160 + 7 ---
+int(9223372034707292167)
+--- testing: 9223372034707292160 + 9 ---
+int(9223372034707292169)
+--- testing: 9223372034707292160 + 65 ---
+int(9223372034707292225)
+--- testing: 9223372034707292160 + -44 ---
+int(9223372034707292116)
+--- testing: 9223372034707292160 + 2147483647 ---
+int(9223372036854775807)
+--- testing: 9223372034707292160 + 9223372036854775807 ---
+float(1.8446744071562E+19)
+--- testing: -9223372034707292160 + 0 ---
+int(-9223372034707292160)
+--- testing: -9223372034707292160 + 1 ---
+int(-9223372034707292159)
+--- testing: -9223372034707292160 + -1 ---
+int(-9223372034707292161)
+--- testing: -9223372034707292160 + 7 ---
+int(-9223372034707292153)
+--- testing: -9223372034707292160 + 9 ---
+int(-9223372034707292151)
+--- testing: -9223372034707292160 + 65 ---
+int(-9223372034707292095)
+--- testing: -9223372034707292160 + -44 ---
+int(-9223372034707292204)
+--- testing: -9223372034707292160 + 2147483647 ---
+int(-9223372032559808513)
+--- testing: -9223372034707292160 + 9223372036854775807 ---
+int(2147483647)
+--- testing: 2147483648 + 0 ---
+int(2147483648)
+--- testing: 2147483648 + 1 ---
+int(2147483649)
+--- testing: 2147483648 + -1 ---
+int(2147483647)
+--- testing: 2147483648 + 7 ---
+int(2147483655)
+--- testing: 2147483648 + 9 ---
+int(2147483657)
+--- testing: 2147483648 + 65 ---
+int(2147483713)
+--- testing: 2147483648 + -44 ---
+int(2147483604)
+--- testing: 2147483648 + 2147483647 ---
+int(4294967295)
+--- testing: 2147483648 + 9223372036854775807 ---
+float(9.2233720390023E+18)
+--- testing: -2147483649 + 0 ---
+int(-2147483649)
+--- testing: -2147483649 + 1 ---
+int(-2147483648)
+--- testing: -2147483649 + -1 ---
+int(-2147483650)
+--- testing: -2147483649 + 7 ---
+int(-2147483642)
+--- testing: -2147483649 + 9 ---
+int(-2147483640)
+--- testing: -2147483649 + 65 ---
+int(-2147483584)
+--- testing: -2147483649 + -44 ---
+int(-2147483693)
+--- testing: -2147483649 + 2147483647 ---
+int(-2)
+--- testing: -2147483649 + 9223372036854775807 ---
+int(9223372034707292158)
+--- testing: 4294967294 + 0 ---
+int(4294967294)
+--- testing: 4294967294 + 1 ---
+int(4294967295)
+--- testing: 4294967294 + -1 ---
+int(4294967293)
+--- testing: 4294967294 + 7 ---
+int(4294967301)
+--- testing: 4294967294 + 9 ---
+int(4294967303)
+--- testing: 4294967294 + 65 ---
+int(4294967359)
+--- testing: 4294967294 + -44 ---
+int(4294967250)
+--- testing: 4294967294 + 2147483647 ---
+int(6442450941)
+--- testing: 4294967294 + 9223372036854775807 ---
+float(9.2233720411497E+18)
+--- testing: 4294967295 + 0 ---
+int(4294967295)
+--- testing: 4294967295 + 1 ---
+int(4294967296)
+--- testing: 4294967295 + -1 ---
+int(4294967294)
+--- testing: 4294967295 + 7 ---
+int(4294967302)
+--- testing: 4294967295 + 9 ---
+int(4294967304)
+--- testing: 4294967295 + 65 ---
+int(4294967360)
+--- testing: 4294967295 + -44 ---
+int(4294967251)
+--- testing: 4294967295 + 2147483647 ---
+int(6442450942)
+--- testing: 4294967295 + 9223372036854775807 ---
+float(9.2233720411497E+18)
+--- testing: 4294967293 + 0 ---
+int(4294967293)
+--- testing: 4294967293 + 1 ---
+int(4294967294)
+--- testing: 4294967293 + -1 ---
+int(4294967292)
+--- testing: 4294967293 + 7 ---
+int(4294967300)
+--- testing: 4294967293 + 9 ---
+int(4294967302)
+--- testing: 4294967293 + 65 ---
+int(4294967358)
+--- testing: 4294967293 + -44 ---
+int(4294967249)
+--- testing: 4294967293 + 2147483647 ---
+int(6442450940)
+--- testing: 4294967293 + 9223372036854775807 ---
+float(9.2233720411497E+18)
+--- testing: 9223372036854775806 + 0 ---
+int(9223372036854775806)
+--- testing: 9223372036854775806 + 1 ---
+int(9223372036854775807)
+--- testing: 9223372036854775806 + -1 ---
+int(9223372036854775805)
+--- testing: 9223372036854775806 + 7 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775806 + 9 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775806 + 65 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775806 + -44 ---
+int(9223372036854775762)
+--- testing: 9223372036854775806 + 2147483647 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775806 + 9223372036854775807 ---
+float(1.844674407371E+19)
+--- testing: 9.2233720368548E+18 + 0 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + 1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + -1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + 7 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + 9 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + 65 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + -44 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 + 2147483647 ---
+float(9.2233720390023E+18)
+--- testing: 9.2233720368548E+18 + 9223372036854775807 ---
+float(1.844674407371E+19)
+--- testing: -9223372036854775807 + 0 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775807 + 1 ---
+int(-9223372036854775806)
+--- testing: -9223372036854775807 + -1 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775807 + 7 ---
+int(-9223372036854775800)
+--- testing: -9223372036854775807 + 9 ---
+int(-9223372036854775798)
+--- testing: -9223372036854775807 + 65 ---
+int(-9223372036854775742)
+--- testing: -9223372036854775807 + -44 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775807 + 2147483647 ---
+int(-9223372034707292160)
+--- testing: -9223372036854775807 + 9223372036854775807 ---
+int(0)
+--- testing: -9.2233720368548E+18 + 0 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + 1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + -1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + 7 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + 9 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + 65 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + -44 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 + 2147483647 ---
+float(-9.2233720347073E+18)
+--- testing: -9.2233720368548E+18 + 9223372036854775807 ---
+float(0)
+--- testing: 0 + 9223372036854775807 ---
+int(9223372036854775807)
+--- testing: 0 + -9223372036854775808 ---
+int(-9223372036854775808)
+--- testing: 0 + 2147483647 ---
+int(2147483647)
+--- testing: 0 + -2147483648 ---
+int(-2147483648)
+--- testing: 0 + 9223372034707292160 ---
+int(9223372034707292160)
+--- testing: 0 + -9223372034707292160 ---
+int(-9223372034707292160)
+--- testing: 0 + 2147483648 ---
+int(2147483648)
+--- testing: 0 + -2147483649 ---
+int(-2147483649)
+--- testing: 0 + 4294967294 ---
+int(4294967294)
+--- testing: 0 + 4294967295 ---
+int(4294967295)
+--- testing: 0 + 4294967293 ---
+int(4294967293)
+--- testing: 0 + 9223372036854775806 ---
+int(9223372036854775806)
+--- testing: 0 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 0 + -9223372036854775807 ---
+int(-9223372036854775807)
+--- testing: 0 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 1 + 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 1 + -9223372036854775808 ---
+int(-9223372036854775807)
+--- testing: 1 + 2147483647 ---
+int(2147483648)
+--- testing: 1 + -2147483648 ---
+int(-2147483647)
+--- testing: 1 + 9223372034707292160 ---
+int(9223372034707292161)
+--- testing: 1 + -9223372034707292160 ---
+int(-9223372034707292159)
+--- testing: 1 + 2147483648 ---
+int(2147483649)
+--- testing: 1 + -2147483649 ---
+int(-2147483648)
+--- testing: 1 + 4294967294 ---
+int(4294967295)
+--- testing: 1 + 4294967295 ---
+int(4294967296)
+--- testing: 1 + 4294967293 ---
+int(4294967294)
+--- testing: 1 + 9223372036854775806 ---
+int(9223372036854775807)
+--- testing: 1 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 1 + -9223372036854775807 ---
+int(-9223372036854775806)
+--- testing: 1 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -1 + 9223372036854775807 ---
+int(9223372036854775806)
+--- testing: -1 + -9223372036854775808 ---
+float(-9.2233720368548E+18)
+--- testing: -1 + 2147483647 ---
+int(2147483646)
+--- testing: -1 + -2147483648 ---
+int(-2147483649)
+--- testing: -1 + 9223372034707292160 ---
+int(9223372034707292159)
+--- testing: -1 + -9223372034707292160 ---
+int(-9223372034707292161)
+--- testing: -1 + 2147483648 ---
+int(2147483647)
+--- testing: -1 + -2147483649 ---
+int(-2147483650)
+--- testing: -1 + 4294967294 ---
+int(4294967293)
+--- testing: -1 + 4294967295 ---
+int(4294967294)
+--- testing: -1 + 4294967293 ---
+int(4294967292)
+--- testing: -1 + 9223372036854775806 ---
+int(9223372036854775805)
+--- testing: -1 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -1 + -9223372036854775807 ---
+int(-9223372036854775808)
+--- testing: -1 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 7 + 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 7 + -9223372036854775808 ---
+int(-9223372036854775801)
+--- testing: 7 + 2147483647 ---
+int(2147483654)
+--- testing: 7 + -2147483648 ---
+int(-2147483641)
+--- testing: 7 + 9223372034707292160 ---
+int(9223372034707292167)
+--- testing: 7 + -9223372034707292160 ---
+int(-9223372034707292153)
+--- testing: 7 + 2147483648 ---
+int(2147483655)
+--- testing: 7 + -2147483649 ---
+int(-2147483642)
+--- testing: 7 + 4294967294 ---
+int(4294967301)
+--- testing: 7 + 4294967295 ---
+int(4294967302)
+--- testing: 7 + 4294967293 ---
+int(4294967300)
+--- testing: 7 + 9223372036854775806 ---
+float(9.2233720368548E+18)
+--- testing: 7 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 7 + -9223372036854775807 ---
+int(-9223372036854775800)
+--- testing: 7 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 9 + 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 9 + -9223372036854775808 ---
+int(-9223372036854775799)
+--- testing: 9 + 2147483647 ---
+int(2147483656)
+--- testing: 9 + -2147483648 ---
+int(-2147483639)
+--- testing: 9 + 9223372034707292160 ---
+int(9223372034707292169)
+--- testing: 9 + -9223372034707292160 ---
+int(-9223372034707292151)
+--- testing: 9 + 2147483648 ---
+int(2147483657)
+--- testing: 9 + -2147483649 ---
+int(-2147483640)
+--- testing: 9 + 4294967294 ---
+int(4294967303)
+--- testing: 9 + 4294967295 ---
+int(4294967304)
+--- testing: 9 + 4294967293 ---
+int(4294967302)
+--- testing: 9 + 9223372036854775806 ---
+float(9.2233720368548E+18)
+--- testing: 9 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 9 + -9223372036854775807 ---
+int(-9223372036854775798)
+--- testing: 9 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 65 + 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 65 + -9223372036854775808 ---
+int(-9223372036854775743)
+--- testing: 65 + 2147483647 ---
+int(2147483712)
+--- testing: 65 + -2147483648 ---
+int(-2147483583)
+--- testing: 65 + 9223372034707292160 ---
+int(9223372034707292225)
+--- testing: 65 + -9223372034707292160 ---
+int(-9223372034707292095)
+--- testing: 65 + 2147483648 ---
+int(2147483713)
+--- testing: 65 + -2147483649 ---
+int(-2147483584)
+--- testing: 65 + 4294967294 ---
+int(4294967359)
+--- testing: 65 + 4294967295 ---
+int(4294967360)
+--- testing: 65 + 4294967293 ---
+int(4294967358)
+--- testing: 65 + 9223372036854775806 ---
+float(9.2233720368548E+18)
+--- testing: 65 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 65 + -9223372036854775807 ---
+int(-9223372036854775742)
+--- testing: 65 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -44 + 9223372036854775807 ---
+int(9223372036854775763)
+--- testing: -44 + -9223372036854775808 ---
+float(-9.2233720368548E+18)
+--- testing: -44 + 2147483647 ---
+int(2147483603)
+--- testing: -44 + -2147483648 ---
+int(-2147483692)
+--- testing: -44 + 9223372034707292160 ---
+int(9223372034707292116)
+--- testing: -44 + -9223372034707292160 ---
+int(-9223372034707292204)
+--- testing: -44 + 2147483648 ---
+int(2147483604)
+--- testing: -44 + -2147483649 ---
+int(-2147483693)
+--- testing: -44 + 4294967294 ---
+int(4294967250)
+--- testing: -44 + 4294967295 ---
+int(4294967251)
+--- testing: -44 + 4294967293 ---
+int(4294967249)
+--- testing: -44 + 9223372036854775806 ---
+int(9223372036854775762)
+--- testing: -44 + 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -44 + -9223372036854775807 ---
+float(-9.2233720368548E+18)
+--- testing: -44 + -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 2147483647 + 9223372036854775807 ---
+float(9.2233720390023E+18)
+--- testing: 2147483647 + -9223372036854775808 ---
+int(-9223372034707292161)
+--- testing: 2147483647 + 2147483647 ---
+int(4294967294)
+--- testing: 2147483647 + -2147483648 ---
+int(-1)
+--- testing: 2147483647 + 9223372034707292160 ---
+int(9223372036854775807)
+--- testing: 2147483647 + -9223372034707292160 ---
+int(-9223372032559808513)
+--- testing: 2147483647 + 2147483648 ---
+int(4294967295)
+--- testing: 2147483647 + -2147483649 ---
+int(-2)
+--- testing: 2147483647 + 4294967294 ---
+int(6442450941)
+--- testing: 2147483647 + 4294967295 ---
+int(6442450942)
+--- testing: 2147483647 + 4294967293 ---
+int(6442450940)
+--- testing: 2147483647 + 9223372036854775806 ---
+float(9.2233720390023E+18)
+--- testing: 2147483647 + 9.2233720368548E+18 ---
+float(9.2233720390023E+18)
+--- testing: 2147483647 + -9223372036854775807 ---
+int(-9223372034707292160)
+--- testing: 2147483647 + -9.2233720368548E+18 ---
+float(-9.2233720347073E+18)
+--- testing: 9223372036854775807 + 9223372036854775807 ---
+float(1.844674407371E+19)
+--- testing: 9223372036854775807 + -9223372036854775808 ---
+int(-1)
+--- testing: 9223372036854775807 + 2147483647 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 + -2147483648 ---
+int(9223372034707292159)
+--- testing: 9223372036854775807 + 9223372034707292160 ---
+float(1.8446744071562E+19)
+--- testing: 9223372036854775807 + -9223372034707292160 ---
+int(2147483647)
+--- testing: 9223372036854775807 + 2147483648 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 + -2147483649 ---
+int(9223372034707292158)
+--- testing: 9223372036854775807 + 4294967294 ---
+float(9.2233720411497E+18)
+--- testing: 9223372036854775807 + 4294967295 ---
+float(9.2233720411497E+18)
+--- testing: 9223372036854775807 + 4294967293 ---
+float(9.2233720411497E+18)
+--- testing: 9223372036854775807 + 9223372036854775806 ---
+float(1.844674407371E+19)
+--- testing: 9223372036854775807 + 9.2233720368548E+18 ---
+float(1.844674407371E+19)
+--- testing: 9223372036854775807 + -9223372036854775807 ---
+int(0)
+--- testing: 9223372036854775807 + -9.2233720368548E+18 ---
+float(0)
+===DONE===
diff --git a/tests/lang/operators/add_variationStr.phpt b/tests/lang/operators/add_variationStr.phpt
new file mode 100644
index 0000000000..264c5c1bb9
--- /dev/null
+++ b/tests/lang/operators/add_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test + operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' + '$otherVal' ---\n";
+ var_dump($strVal+$otherVal);
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' + '0' ---
+int(0)
+--- testing: '0' + '65' ---
+int(65)
+--- testing: '0' + '-44' ---
+int(-44)
+--- testing: '0' + '1.2' ---
+float(1.2)
+--- testing: '0' + '-7.7' ---
+float(-7.7)
+--- testing: '0' + 'abc' ---
+int(0)
+--- testing: '0' + '123abc' ---
+int(123)
+--- testing: '0' + '123e5' ---
+float(12300000)
+--- testing: '0' + '123e5xyz' ---
+float(12300000)
+--- testing: '0' + ' 123abc' ---
+int(123)
+--- testing: '0' + '123 abc' ---
+int(123)
+--- testing: '0' + '123abc ' ---
+int(123)
+--- testing: '0' + '3.4a' ---
+float(3.4)
+--- testing: '0' + 'a5.9' ---
+int(0)
+--- testing: '65' + '0' ---
+int(65)
+--- testing: '65' + '65' ---
+int(130)
+--- testing: '65' + '-44' ---
+int(21)
+--- testing: '65' + '1.2' ---
+float(66.2)
+--- testing: '65' + '-7.7' ---
+float(57.3)
+--- testing: '65' + 'abc' ---
+int(65)
+--- testing: '65' + '123abc' ---
+int(188)
+--- testing: '65' + '123e5' ---
+float(12300065)
+--- testing: '65' + '123e5xyz' ---
+float(12300065)
+--- testing: '65' + ' 123abc' ---
+int(188)
+--- testing: '65' + '123 abc' ---
+int(188)
+--- testing: '65' + '123abc ' ---
+int(188)
+--- testing: '65' + '3.4a' ---
+float(68.4)
+--- testing: '65' + 'a5.9' ---
+int(65)
+--- testing: '-44' + '0' ---
+int(-44)
+--- testing: '-44' + '65' ---
+int(21)
+--- testing: '-44' + '-44' ---
+int(-88)
+--- testing: '-44' + '1.2' ---
+float(-42.8)
+--- testing: '-44' + '-7.7' ---
+float(-51.7)
+--- testing: '-44' + 'abc' ---
+int(-44)
+--- testing: '-44' + '123abc' ---
+int(79)
+--- testing: '-44' + '123e5' ---
+float(12299956)
+--- testing: '-44' + '123e5xyz' ---
+float(12299956)
+--- testing: '-44' + ' 123abc' ---
+int(79)
+--- testing: '-44' + '123 abc' ---
+int(79)
+--- testing: '-44' + '123abc ' ---
+int(79)
+--- testing: '-44' + '3.4a' ---
+float(-40.6)
+--- testing: '-44' + 'a5.9' ---
+int(-44)
+--- testing: '1.2' + '0' ---
+float(1.2)
+--- testing: '1.2' + '65' ---
+float(66.2)
+--- testing: '1.2' + '-44' ---
+float(-42.8)
+--- testing: '1.2' + '1.2' ---
+float(2.4)
+--- testing: '1.2' + '-7.7' ---
+float(-6.5)
+--- testing: '1.2' + 'abc' ---
+float(1.2)
+--- testing: '1.2' + '123abc' ---
+float(124.2)
+--- testing: '1.2' + '123e5' ---
+float(12300001.2)
+--- testing: '1.2' + '123e5xyz' ---
+float(12300001.2)
+--- testing: '1.2' + ' 123abc' ---
+float(124.2)
+--- testing: '1.2' + '123 abc' ---
+float(124.2)
+--- testing: '1.2' + '123abc ' ---
+float(124.2)
+--- testing: '1.2' + '3.4a' ---
+float(4.6)
+--- testing: '1.2' + 'a5.9' ---
+float(1.2)
+--- testing: '-7.7' + '0' ---
+float(-7.7)
+--- testing: '-7.7' + '65' ---
+float(57.3)
+--- testing: '-7.7' + '-44' ---
+float(-51.7)
+--- testing: '-7.7' + '1.2' ---
+float(-6.5)
+--- testing: '-7.7' + '-7.7' ---
+float(-15.4)
+--- testing: '-7.7' + 'abc' ---
+float(-7.7)
+--- testing: '-7.7' + '123abc' ---
+float(115.3)
+--- testing: '-7.7' + '123e5' ---
+float(12299992.3)
+--- testing: '-7.7' + '123e5xyz' ---
+float(12299992.3)
+--- testing: '-7.7' + ' 123abc' ---
+float(115.3)
+--- testing: '-7.7' + '123 abc' ---
+float(115.3)
+--- testing: '-7.7' + '123abc ' ---
+float(115.3)
+--- testing: '-7.7' + '3.4a' ---
+float(-4.3)
+--- testing: '-7.7' + 'a5.9' ---
+float(-7.7)
+--- testing: 'abc' + '0' ---
+int(0)
+--- testing: 'abc' + '65' ---
+int(65)
+--- testing: 'abc' + '-44' ---
+int(-44)
+--- testing: 'abc' + '1.2' ---
+float(1.2)
+--- testing: 'abc' + '-7.7' ---
+float(-7.7)
+--- testing: 'abc' + 'abc' ---
+int(0)
+--- testing: 'abc' + '123abc' ---
+int(123)
+--- testing: 'abc' + '123e5' ---
+float(12300000)
+--- testing: 'abc' + '123e5xyz' ---
+float(12300000)
+--- testing: 'abc' + ' 123abc' ---
+int(123)
+--- testing: 'abc' + '123 abc' ---
+int(123)
+--- testing: 'abc' + '123abc ' ---
+int(123)
+--- testing: 'abc' + '3.4a' ---
+float(3.4)
+--- testing: 'abc' + 'a5.9' ---
+int(0)
+--- testing: '123abc' + '0' ---
+int(123)
+--- testing: '123abc' + '65' ---
+int(188)
+--- testing: '123abc' + '-44' ---
+int(79)
+--- testing: '123abc' + '1.2' ---
+float(124.2)
+--- testing: '123abc' + '-7.7' ---
+float(115.3)
+--- testing: '123abc' + 'abc' ---
+int(123)
+--- testing: '123abc' + '123abc' ---
+int(246)
+--- testing: '123abc' + '123e5' ---
+float(12300123)
+--- testing: '123abc' + '123e5xyz' ---
+float(12300123)
+--- testing: '123abc' + ' 123abc' ---
+int(246)
+--- testing: '123abc' + '123 abc' ---
+int(246)
+--- testing: '123abc' + '123abc ' ---
+int(246)
+--- testing: '123abc' + '3.4a' ---
+float(126.4)
+--- testing: '123abc' + 'a5.9' ---
+int(123)
+--- testing: '123e5' + '0' ---
+float(12300000)
+--- testing: '123e5' + '65' ---
+float(12300065)
+--- testing: '123e5' + '-44' ---
+float(12299956)
+--- testing: '123e5' + '1.2' ---
+float(12300001.2)
+--- testing: '123e5' + '-7.7' ---
+float(12299992.3)
+--- testing: '123e5' + 'abc' ---
+float(12300000)
+--- testing: '123e5' + '123abc' ---
+float(12300123)
+--- testing: '123e5' + '123e5' ---
+float(24600000)
+--- testing: '123e5' + '123e5xyz' ---
+float(24600000)
+--- testing: '123e5' + ' 123abc' ---
+float(12300123)
+--- testing: '123e5' + '123 abc' ---
+float(12300123)
+--- testing: '123e5' + '123abc ' ---
+float(12300123)
+--- testing: '123e5' + '3.4a' ---
+float(12300003.4)
+--- testing: '123e5' + 'a5.9' ---
+float(12300000)
+--- testing: '123e5xyz' + '0' ---
+float(12300000)
+--- testing: '123e5xyz' + '65' ---
+float(12300065)
+--- testing: '123e5xyz' + '-44' ---
+float(12299956)
+--- testing: '123e5xyz' + '1.2' ---
+float(12300001.2)
+--- testing: '123e5xyz' + '-7.7' ---
+float(12299992.3)
+--- testing: '123e5xyz' + 'abc' ---
+float(12300000)
+--- testing: '123e5xyz' + '123abc' ---
+float(12300123)
+--- testing: '123e5xyz' + '123e5' ---
+float(24600000)
+--- testing: '123e5xyz' + '123e5xyz' ---
+float(24600000)
+--- testing: '123e5xyz' + ' 123abc' ---
+float(12300123)
+--- testing: '123e5xyz' + '123 abc' ---
+float(12300123)
+--- testing: '123e5xyz' + '123abc ' ---
+float(12300123)
+--- testing: '123e5xyz' + '3.4a' ---
+float(12300003.4)
+--- testing: '123e5xyz' + 'a5.9' ---
+float(12300000)
+--- testing: ' 123abc' + '0' ---
+int(123)
+--- testing: ' 123abc' + '65' ---
+int(188)
+--- testing: ' 123abc' + '-44' ---
+int(79)
+--- testing: ' 123abc' + '1.2' ---
+float(124.2)
+--- testing: ' 123abc' + '-7.7' ---
+float(115.3)
+--- testing: ' 123abc' + 'abc' ---
+int(123)
+--- testing: ' 123abc' + '123abc' ---
+int(246)
+--- testing: ' 123abc' + '123e5' ---
+float(12300123)
+--- testing: ' 123abc' + '123e5xyz' ---
+float(12300123)
+--- testing: ' 123abc' + ' 123abc' ---
+int(246)
+--- testing: ' 123abc' + '123 abc' ---
+int(246)
+--- testing: ' 123abc' + '123abc ' ---
+int(246)
+--- testing: ' 123abc' + '3.4a' ---
+float(126.4)
+--- testing: ' 123abc' + 'a5.9' ---
+int(123)
+--- testing: '123 abc' + '0' ---
+int(123)
+--- testing: '123 abc' + '65' ---
+int(188)
+--- testing: '123 abc' + '-44' ---
+int(79)
+--- testing: '123 abc' + '1.2' ---
+float(124.2)
+--- testing: '123 abc' + '-7.7' ---
+float(115.3)
+--- testing: '123 abc' + 'abc' ---
+int(123)
+--- testing: '123 abc' + '123abc' ---
+int(246)
+--- testing: '123 abc' + '123e5' ---
+float(12300123)
+--- testing: '123 abc' + '123e5xyz' ---
+float(12300123)
+--- testing: '123 abc' + ' 123abc' ---
+int(246)
+--- testing: '123 abc' + '123 abc' ---
+int(246)
+--- testing: '123 abc' + '123abc ' ---
+int(246)
+--- testing: '123 abc' + '3.4a' ---
+float(126.4)
+--- testing: '123 abc' + 'a5.9' ---
+int(123)
+--- testing: '123abc ' + '0' ---
+int(123)
+--- testing: '123abc ' + '65' ---
+int(188)
+--- testing: '123abc ' + '-44' ---
+int(79)
+--- testing: '123abc ' + '1.2' ---
+float(124.2)
+--- testing: '123abc ' + '-7.7' ---
+float(115.3)
+--- testing: '123abc ' + 'abc' ---
+int(123)
+--- testing: '123abc ' + '123abc' ---
+int(246)
+--- testing: '123abc ' + '123e5' ---
+float(12300123)
+--- testing: '123abc ' + '123e5xyz' ---
+float(12300123)
+--- testing: '123abc ' + ' 123abc' ---
+int(246)
+--- testing: '123abc ' + '123 abc' ---
+int(246)
+--- testing: '123abc ' + '123abc ' ---
+int(246)
+--- testing: '123abc ' + '3.4a' ---
+float(126.4)
+--- testing: '123abc ' + 'a5.9' ---
+int(123)
+--- testing: '3.4a' + '0' ---
+float(3.4)
+--- testing: '3.4a' + '65' ---
+float(68.4)
+--- testing: '3.4a' + '-44' ---
+float(-40.6)
+--- testing: '3.4a' + '1.2' ---
+float(4.6)
+--- testing: '3.4a' + '-7.7' ---
+float(-4.3)
+--- testing: '3.4a' + 'abc' ---
+float(3.4)
+--- testing: '3.4a' + '123abc' ---
+float(126.4)
+--- testing: '3.4a' + '123e5' ---
+float(12300003.4)
+--- testing: '3.4a' + '123e5xyz' ---
+float(12300003.4)
+--- testing: '3.4a' + ' 123abc' ---
+float(126.4)
+--- testing: '3.4a' + '123 abc' ---
+float(126.4)
+--- testing: '3.4a' + '123abc ' ---
+float(126.4)
+--- testing: '3.4a' + '3.4a' ---
+float(6.8)
+--- testing: '3.4a' + 'a5.9' ---
+float(3.4)
+--- testing: 'a5.9' + '0' ---
+int(0)
+--- testing: 'a5.9' + '65' ---
+int(65)
+--- testing: 'a5.9' + '-44' ---
+int(-44)
+--- testing: 'a5.9' + '1.2' ---
+float(1.2)
+--- testing: 'a5.9' + '-7.7' ---
+float(-7.7)
+--- testing: 'a5.9' + 'abc' ---
+int(0)
+--- testing: 'a5.9' + '123abc' ---
+int(123)
+--- testing: 'a5.9' + '123e5' ---
+float(12300000)
+--- testing: 'a5.9' + '123e5xyz' ---
+float(12300000)
+--- testing: 'a5.9' + ' 123abc' ---
+int(123)
+--- testing: 'a5.9' + '123 abc' ---
+int(123)
+--- testing: 'a5.9' + '123abc ' ---
+int(123)
+--- testing: 'a5.9' + '3.4a' ---
+float(3.4)
+--- testing: 'a5.9' + 'a5.9' ---
+int(0)
+===DONE===
diff --git a/tests/lang/operators/bitwiseAnd_variationStr.phpt b/tests/lang/operators/bitwiseAnd_variationStr.phpt
new file mode 100644
index 0000000000..26022705fc
--- /dev/null
+++ b/tests/lang/operators/bitwiseAnd_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test & operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' & '$otherVal' ---\n";
+ var_dump(bin2hex($strVal&$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' & '0' ---
+string(2) "30"
+--- testing: '0' & '65' ---
+string(2) "30"
+--- testing: '0' & '-44' ---
+string(2) "20"
+--- testing: '0' & '1.2' ---
+string(2) "30"
+--- testing: '0' & '-7.7' ---
+string(2) "20"
+--- testing: '0' & 'abc' ---
+string(2) "20"
+--- testing: '0' & '123abc' ---
+string(2) "30"
+--- testing: '0' & '123e5' ---
+string(2) "30"
+--- testing: '0' & '123e5xyz' ---
+string(2) "30"
+--- testing: '0' & ' 123abc' ---
+string(2) "20"
+--- testing: '0' & '123 abc' ---
+string(2) "30"
+--- testing: '0' & '123abc ' ---
+string(2) "30"
+--- testing: '0' & '3.4a' ---
+string(2) "30"
+--- testing: '0' & 'a5.9' ---
+string(2) "20"
+--- testing: '65' & '0' ---
+string(2) "30"
+--- testing: '65' & '65' ---
+string(4) "3635"
+--- testing: '65' & '-44' ---
+string(4) "2434"
+--- testing: '65' & '1.2' ---
+string(4) "3024"
+--- testing: '65' & '-7.7' ---
+string(4) "2435"
+--- testing: '65' & 'abc' ---
+string(4) "2020"
+--- testing: '65' & '123abc' ---
+string(4) "3030"
+--- testing: '65' & '123e5' ---
+string(4) "3030"
+--- testing: '65' & '123e5xyz' ---
+string(4) "3030"
+--- testing: '65' & ' 123abc' ---
+string(4) "2031"
+--- testing: '65' & '123 abc' ---
+string(4) "3030"
+--- testing: '65' & '123abc ' ---
+string(4) "3030"
+--- testing: '65' & '3.4a' ---
+string(4) "3224"
+--- testing: '65' & 'a5.9' ---
+string(4) "2035"
+--- testing: '-44' & '0' ---
+string(2) "20"
+--- testing: '-44' & '65' ---
+string(4) "2434"
+--- testing: '-44' & '-44' ---
+string(6) "2d3434"
+--- testing: '-44' & '1.2' ---
+string(6) "212430"
+--- testing: '-44' & '-7.7' ---
+string(6) "2d3424"
+--- testing: '-44' & 'abc' ---
+string(6) "212020"
+--- testing: '-44' & '123abc' ---
+string(6) "213030"
+--- testing: '-44' & '123e5' ---
+string(6) "213030"
+--- testing: '-44' & '123e5xyz' ---
+string(6) "213030"
+--- testing: '-44' & ' 123abc' ---
+string(6) "203030"
+--- testing: '-44' & '123 abc' ---
+string(6) "213030"
+--- testing: '-44' & '123abc ' ---
+string(6) "213030"
+--- testing: '-44' & '3.4a' ---
+string(6) "212434"
+--- testing: '-44' & 'a5.9' ---
+string(6) "213424"
+--- testing: '1.2' & '0' ---
+string(2) "30"
+--- testing: '1.2' & '65' ---
+string(4) "3024"
+--- testing: '1.2' & '-44' ---
+string(6) "212430"
+--- testing: '1.2' & '1.2' ---
+string(6) "312e32"
+--- testing: '1.2' & '-7.7' ---
+string(6) "212622"
+--- testing: '1.2' & 'abc' ---
+string(6) "212222"
+--- testing: '1.2' & '123abc' ---
+string(6) "312232"
+--- testing: '1.2' & '123e5' ---
+string(6) "312232"
+--- testing: '1.2' & '123e5xyz' ---
+string(6) "312232"
+--- testing: '1.2' & ' 123abc' ---
+string(6) "202032"
+--- testing: '1.2' & '123 abc' ---
+string(6) "312232"
+--- testing: '1.2' & '123abc ' ---
+string(6) "312232"
+--- testing: '1.2' & '3.4a' ---
+string(6) "312e30"
+--- testing: '1.2' & 'a5.9' ---
+string(6) "212422"
+--- testing: '-7.7' & '0' ---
+string(2) "20"
+--- testing: '-7.7' & '65' ---
+string(4) "2435"
+--- testing: '-7.7' & '-44' ---
+string(6) "2d3424"
+--- testing: '-7.7' & '1.2' ---
+string(6) "212622"
+--- testing: '-7.7' & '-7.7' ---
+string(8) "2d372e37"
+--- testing: '-7.7' & 'abc' ---
+string(6) "212222"
+--- testing: '-7.7' & '123abc' ---
+string(8) "21322221"
+--- testing: '-7.7' & '123e5' ---
+string(8) "21322225"
+--- testing: '-7.7' & '123e5xyz' ---
+string(8) "21322225"
+--- testing: '-7.7' & ' 123abc' ---
+string(8) "20312233"
+--- testing: '-7.7' & '123 abc' ---
+string(8) "21322220"
+--- testing: '-7.7' & '123abc ' ---
+string(8) "21322221"
+--- testing: '-7.7' & '3.4a' ---
+string(8) "21262421"
+--- testing: '-7.7' & 'a5.9' ---
+string(8) "21352e31"
+--- testing: 'abc' & '0' ---
+string(2) "20"
+--- testing: 'abc' & '65' ---
+string(4) "2020"
+--- testing: 'abc' & '-44' ---
+string(6) "212020"
+--- testing: 'abc' & '1.2' ---
+string(6) "212222"
+--- testing: 'abc' & '-7.7' ---
+string(6) "212222"
+--- testing: 'abc' & 'abc' ---
+string(6) "616263"
+--- testing: 'abc' & '123abc' ---
+string(6) "212223"
+--- testing: 'abc' & '123e5' ---
+string(6) "212223"
+--- testing: 'abc' & '123e5xyz' ---
+string(6) "212223"
+--- testing: 'abc' & ' 123abc' ---
+string(6) "202022"
+--- testing: 'abc' & '123 abc' ---
+string(6) "212223"
+--- testing: 'abc' & '123abc ' ---
+string(6) "212223"
+--- testing: 'abc' & '3.4a' ---
+string(6) "212220"
+--- testing: 'abc' & 'a5.9' ---
+string(6) "612022"
+--- testing: '123abc' & '0' ---
+string(2) "30"
+--- testing: '123abc' & '65' ---
+string(4) "3030"
+--- testing: '123abc' & '-44' ---
+string(6) "213030"
+--- testing: '123abc' & '1.2' ---
+string(6) "312232"
+--- testing: '123abc' & '-7.7' ---
+string(8) "21322221"
+--- testing: '123abc' & 'abc' ---
+string(6) "212223"
+--- testing: '123abc' & '123abc' ---
+string(12) "313233616263"
+--- testing: '123abc' & '123e5' ---
+string(10) "3132336120"
+--- testing: '123abc' & '123e5xyz' ---
+string(12) "313233612060"
+--- testing: '123abc' & ' 123abc' ---
+string(12) "203032216062"
+--- testing: '123abc' & '123 abc' ---
+string(12) "313233206062"
+--- testing: '123abc' & '123abc ' ---
+string(12) "313233616263"
+--- testing: '123abc' & '3.4a' ---
+string(8) "31223061"
+--- testing: '123abc' & 'a5.9' ---
+string(8) "21302221"
+--- testing: '123e5' & '0' ---
+string(2) "30"
+--- testing: '123e5' & '65' ---
+string(4) "3030"
+--- testing: '123e5' & '-44' ---
+string(6) "213030"
+--- testing: '123e5' & '1.2' ---
+string(6) "312232"
+--- testing: '123e5' & '-7.7' ---
+string(8) "21322225"
+--- testing: '123e5' & 'abc' ---
+string(6) "212223"
+--- testing: '123e5' & '123abc' ---
+string(10) "3132336120"
+--- testing: '123e5' & '123e5' ---
+string(10) "3132336535"
+--- testing: '123e5' & '123e5xyz' ---
+string(10) "3132336535"
+--- testing: '123e5' & ' 123abc' ---
+string(10) "2030322121"
+--- testing: '123e5' & '123 abc' ---
+string(10) "3132332021"
+--- testing: '123e5' & '123abc ' ---
+string(10) "3132336120"
+--- testing: '123e5' & '3.4a' ---
+string(8) "31223061"
+--- testing: '123e5' & 'a5.9' ---
+string(8) "21302221"
+--- testing: '123e5xyz' & '0' ---
+string(2) "30"
+--- testing: '123e5xyz' & '65' ---
+string(4) "3030"
+--- testing: '123e5xyz' & '-44' ---
+string(6) "213030"
+--- testing: '123e5xyz' & '1.2' ---
+string(6) "312232"
+--- testing: '123e5xyz' & '-7.7' ---
+string(8) "21322225"
+--- testing: '123e5xyz' & 'abc' ---
+string(6) "212223"
+--- testing: '123e5xyz' & '123abc' ---
+string(12) "313233612060"
+--- testing: '123e5xyz' & '123e5' ---
+string(10) "3132336535"
+--- testing: '123e5xyz' & '123e5xyz' ---
+string(16) "313233653578797a"
+--- testing: '123e5xyz' & ' 123abc' ---
+string(14) "20303221216061"
+--- testing: '123e5xyz' & '123 abc' ---
+string(14) "31323320216061"
+--- testing: '123e5xyz' & '123abc ' ---
+string(14) "31323361206020"
+--- testing: '123e5xyz' & '3.4a' ---
+string(8) "31223061"
+--- testing: '123e5xyz' & 'a5.9' ---
+string(8) "21302221"
+--- testing: ' 123abc' & '0' ---
+string(2) "20"
+--- testing: ' 123abc' & '65' ---
+string(4) "2031"
+--- testing: ' 123abc' & '-44' ---
+string(6) "203030"
+--- testing: ' 123abc' & '1.2' ---
+string(6) "202032"
+--- testing: ' 123abc' & '-7.7' ---
+string(8) "20312233"
+--- testing: ' 123abc' & 'abc' ---
+string(6) "202022"
+--- testing: ' 123abc' & '123abc' ---
+string(12) "203032216062"
+--- testing: ' 123abc' & '123e5' ---
+string(10) "2030322121"
+--- testing: ' 123abc' & '123e5xyz' ---
+string(14) "20303221216061"
+--- testing: ' 123abc' & ' 123abc' ---
+string(14) "20313233616263"
+--- testing: ' 123abc' & '123 abc' ---
+string(14) "20303220616263"
+--- testing: ' 123abc' & '123abc ' ---
+string(14) "20303221606220"
+--- testing: ' 123abc' & '3.4a' ---
+string(8) "20203021"
+--- testing: ' 123abc' & 'a5.9' ---
+string(8) "20312231"
+--- testing: '123 abc' & '0' ---
+string(2) "30"
+--- testing: '123 abc' & '65' ---
+string(4) "3030"
+--- testing: '123 abc' & '-44' ---
+string(6) "213030"
+--- testing: '123 abc' & '1.2' ---
+string(6) "312232"
+--- testing: '123 abc' & '-7.7' ---
+string(8) "21322220"
+--- testing: '123 abc' & 'abc' ---
+string(6) "212223"
+--- testing: '123 abc' & '123abc' ---
+string(12) "313233206062"
+--- testing: '123 abc' & '123e5' ---
+string(10) "3132332021"
+--- testing: '123 abc' & '123e5xyz' ---
+string(14) "31323320216061"
+--- testing: '123 abc' & ' 123abc' ---
+string(14) "20303220616263"
+--- testing: '123 abc' & '123 abc' ---
+string(14) "31323320616263"
+--- testing: '123 abc' & '123abc ' ---
+string(14) "31323320606220"
+--- testing: '123 abc' & '3.4a' ---
+string(8) "31223020"
+--- testing: '123 abc' & 'a5.9' ---
+string(8) "21302220"
+--- testing: '123abc ' & '0' ---
+string(2) "30"
+--- testing: '123abc ' & '65' ---
+string(4) "3030"
+--- testing: '123abc ' & '-44' ---
+string(6) "213030"
+--- testing: '123abc ' & '1.2' ---
+string(6) "312232"
+--- testing: '123abc ' & '-7.7' ---
+string(8) "21322221"
+--- testing: '123abc ' & 'abc' ---
+string(6) "212223"
+--- testing: '123abc ' & '123abc' ---
+string(12) "313233616263"
+--- testing: '123abc ' & '123e5' ---
+string(10) "3132336120"
+--- testing: '123abc ' & '123e5xyz' ---
+string(14) "31323361206020"
+--- testing: '123abc ' & ' 123abc' ---
+string(14) "20303221606220"
+--- testing: '123abc ' & '123 abc' ---
+string(14) "31323320606220"
+--- testing: '123abc ' & '123abc ' ---
+string(14) "31323361626320"
+--- testing: '123abc ' & '3.4a' ---
+string(8) "31223061"
+--- testing: '123abc ' & 'a5.9' ---
+string(8) "21302221"
+--- testing: '3.4a' & '0' ---
+string(2) "30"
+--- testing: '3.4a' & '65' ---
+string(4) "3224"
+--- testing: '3.4a' & '-44' ---
+string(6) "212434"
+--- testing: '3.4a' & '1.2' ---
+string(6) "312e30"
+--- testing: '3.4a' & '-7.7' ---
+string(8) "21262421"
+--- testing: '3.4a' & 'abc' ---
+string(6) "212220"
+--- testing: '3.4a' & '123abc' ---
+string(8) "31223061"
+--- testing: '3.4a' & '123e5' ---
+string(8) "31223061"
+--- testing: '3.4a' & '123e5xyz' ---
+string(8) "31223061"
+--- testing: '3.4a' & ' 123abc' ---
+string(8) "20203021"
+--- testing: '3.4a' & '123 abc' ---
+string(8) "31223020"
+--- testing: '3.4a' & '123abc ' ---
+string(8) "31223061"
+--- testing: '3.4a' & '3.4a' ---
+string(8) "332e3461"
+--- testing: '3.4a' & 'a5.9' ---
+string(8) "21242421"
+--- testing: 'a5.9' & '0' ---
+string(2) "20"
+--- testing: 'a5.9' & '65' ---
+string(4) "2035"
+--- testing: 'a5.9' & '-44' ---
+string(6) "213424"
+--- testing: 'a5.9' & '1.2' ---
+string(6) "212422"
+--- testing: 'a5.9' & '-7.7' ---
+string(8) "21352e31"
+--- testing: 'a5.9' & 'abc' ---
+string(6) "612022"
+--- testing: 'a5.9' & '123abc' ---
+string(8) "21302221"
+--- testing: 'a5.9' & '123e5' ---
+string(8) "21302221"
+--- testing: 'a5.9' & '123e5xyz' ---
+string(8) "21302221"
+--- testing: 'a5.9' & ' 123abc' ---
+string(8) "20312231"
+--- testing: 'a5.9' & '123 abc' ---
+string(8) "21302220"
+--- testing: 'a5.9' & '123abc ' ---
+string(8) "21302221"
+--- testing: 'a5.9' & '3.4a' ---
+string(8) "21242421"
+--- testing: 'a5.9' & 'a5.9' ---
+string(8) "61352e39"
+===DONE===
diff --git a/tests/lang/operators/bitwiseNot_variationStr.phpt b/tests/lang/operators/bitwiseNot_variationStr.phpt
new file mode 100644
index 0000000000..3e7b698680
--- /dev/null
+++ b/tests/lang/operators/bitwiseNot_variationStr.phpt
@@ -0,0 +1,48 @@
+--TEST--
+Test ~N operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ var_dump(bin2hex(~$strVal));
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+string(2) "cf"
+--- testing: '65' ---
+string(4) "c9ca"
+--- testing: '-44' ---
+string(6) "d2cbcb"
+--- testing: '1.2' ---
+string(6) "ced1cd"
+--- testing: '-7.7' ---
+string(8) "d2c8d1c8"
+--- testing: 'abc' ---
+string(6) "9e9d9c"
+--- testing: '123abc' ---
+string(12) "cecdcc9e9d9c"
+--- testing: '123e5' ---
+string(10) "cecdcc9aca"
+--- testing: '123e5xyz' ---
+string(16) "cecdcc9aca878685"
+--- testing: ' 123abc' ---
+string(14) "dfcecdcc9e9d9c"
+--- testing: '123 abc' ---
+string(14) "cecdccdf9e9d9c"
+--- testing: '123abc ' ---
+string(14) "cecdcc9e9d9cdf"
+--- testing: '3.4a' ---
+string(8) "ccd1cb9e"
+--- testing: 'a5.9' ---
+string(8) "9ecad1c6"
+===DONE===
diff --git a/tests/lang/operators/bitwiseOr_variationStr.phpt b/tests/lang/operators/bitwiseOr_variationStr.phpt
new file mode 100644
index 0000000000..6c31477884
--- /dev/null
+++ b/tests/lang/operators/bitwiseOr_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test | operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' | '$otherVal' ---\n";
+ var_dump(bin2hex($strVal|$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' | '0' ---
+string(2) "30"
+--- testing: '0' | '65' ---
+string(4) "3635"
+--- testing: '0' | '-44' ---
+string(6) "3d3434"
+--- testing: '0' | '1.2' ---
+string(6) "312e32"
+--- testing: '0' | '-7.7' ---
+string(8) "3d372e37"
+--- testing: '0' | 'abc' ---
+string(6) "716263"
+--- testing: '0' | '123abc' ---
+string(12) "313233616263"
+--- testing: '0' | '123e5' ---
+string(10) "3132336535"
+--- testing: '0' | '123e5xyz' ---
+string(16) "313233653578797a"
+--- testing: '0' | ' 123abc' ---
+string(14) "30313233616263"
+--- testing: '0' | '123 abc' ---
+string(14) "31323320616263"
+--- testing: '0' | '123abc ' ---
+string(14) "31323361626320"
+--- testing: '0' | '3.4a' ---
+string(8) "332e3461"
+--- testing: '0' | 'a5.9' ---
+string(8) "71352e39"
+--- testing: '65' | '0' ---
+string(4) "3635"
+--- testing: '65' | '65' ---
+string(4) "3635"
+--- testing: '65' | '-44' ---
+string(6) "3f3534"
+--- testing: '65' | '1.2' ---
+string(6) "373f32"
+--- testing: '65' | '-7.7' ---
+string(8) "3f372e37"
+--- testing: '65' | 'abc' ---
+string(6) "777763"
+--- testing: '65' | '123abc' ---
+string(12) "373733616263"
+--- testing: '65' | '123e5' ---
+string(10) "3737336535"
+--- testing: '65' | '123e5xyz' ---
+string(16) "373733653578797a"
+--- testing: '65' | ' 123abc' ---
+string(14) "36353233616263"
+--- testing: '65' | '123 abc' ---
+string(14) "37373320616263"
+--- testing: '65' | '123abc ' ---
+string(14) "37373361626320"
+--- testing: '65' | '3.4a' ---
+string(8) "373f3461"
+--- testing: '65' | 'a5.9' ---
+string(8) "77352e39"
+--- testing: '-44' | '0' ---
+string(6) "3d3434"
+--- testing: '-44' | '65' ---
+string(6) "3f3534"
+--- testing: '-44' | '-44' ---
+string(6) "2d3434"
+--- testing: '-44' | '1.2' ---
+string(6) "3d3e36"
+--- testing: '-44' | '-7.7' ---
+string(8) "2d373e37"
+--- testing: '-44' | 'abc' ---
+string(6) "6d7677"
+--- testing: '-44' | '123abc' ---
+string(12) "3d3637616263"
+--- testing: '-44' | '123e5' ---
+string(10) "3d36376535"
+--- testing: '-44' | '123e5xyz' ---
+string(16) "3d3637653578797a"
+--- testing: '-44' | ' 123abc' ---
+string(14) "2d353633616263"
+--- testing: '-44' | '123 abc' ---
+string(14) "3d363720616263"
+--- testing: '-44' | '123abc ' ---
+string(14) "3d363761626320"
+--- testing: '-44' | '3.4a' ---
+string(8) "3f3e3461"
+--- testing: '-44' | 'a5.9' ---
+string(8) "6d353e39"
+--- testing: '1.2' | '0' ---
+string(6) "312e32"
+--- testing: '1.2' | '65' ---
+string(6) "373f32"
+--- testing: '1.2' | '-44' ---
+string(6) "3d3e36"
+--- testing: '1.2' | '1.2' ---
+string(6) "312e32"
+--- testing: '1.2' | '-7.7' ---
+string(8) "3d3f3e37"
+--- testing: '1.2' | 'abc' ---
+string(6) "716e73"
+--- testing: '1.2' | '123abc' ---
+string(12) "313e33616263"
+--- testing: '1.2' | '123e5' ---
+string(10) "313e336535"
+--- testing: '1.2' | '123e5xyz' ---
+string(16) "313e33653578797a"
+--- testing: '1.2' | ' 123abc' ---
+string(14) "313f3233616263"
+--- testing: '1.2' | '123 abc' ---
+string(14) "313e3320616263"
+--- testing: '1.2' | '123abc ' ---
+string(14) "313e3361626320"
+--- testing: '1.2' | '3.4a' ---
+string(8) "332e3661"
+--- testing: '1.2' | 'a5.9' ---
+string(8) "713f3e39"
+--- testing: '-7.7' | '0' ---
+string(8) "3d372e37"
+--- testing: '-7.7' | '65' ---
+string(8) "3f372e37"
+--- testing: '-7.7' | '-44' ---
+string(8) "2d373e37"
+--- testing: '-7.7' | '1.2' ---
+string(8) "3d3f3e37"
+--- testing: '-7.7' | '-7.7' ---
+string(8) "2d372e37"
+--- testing: '-7.7' | 'abc' ---
+string(8) "6d776f37"
+--- testing: '-7.7' | '123abc' ---
+string(12) "3d373f776263"
+--- testing: '-7.7' | '123e5' ---
+string(10) "3d373f7735"
+--- testing: '-7.7' | '123e5xyz' ---
+string(16) "3d373f773578797a"
+--- testing: '-7.7' | ' 123abc' ---
+string(14) "2d373e37616263"
+--- testing: '-7.7' | '123 abc' ---
+string(14) "3d373f37616263"
+--- testing: '-7.7' | '123abc ' ---
+string(14) "3d373f77626320"
+--- testing: '-7.7' | '3.4a' ---
+string(8) "3f3f3e77"
+--- testing: '-7.7' | 'a5.9' ---
+string(8) "6d372e3f"
+--- testing: 'abc' | '0' ---
+string(6) "716263"
+--- testing: 'abc' | '65' ---
+string(6) "777763"
+--- testing: 'abc' | '-44' ---
+string(6) "6d7677"
+--- testing: 'abc' | '1.2' ---
+string(6) "716e73"
+--- testing: 'abc' | '-7.7' ---
+string(8) "6d776f37"
+--- testing: 'abc' | 'abc' ---
+string(6) "616263"
+--- testing: 'abc' | '123abc' ---
+string(12) "717273616263"
+--- testing: 'abc' | '123e5' ---
+string(10) "7172736535"
+--- testing: 'abc' | '123e5xyz' ---
+string(16) "717273653578797a"
+--- testing: 'abc' | ' 123abc' ---
+string(14) "61737333616263"
+--- testing: 'abc' | '123 abc' ---
+string(14) "71727320616263"
+--- testing: 'abc' | '123abc ' ---
+string(14) "71727361626320"
+--- testing: 'abc' | '3.4a' ---
+string(8) "736e7761"
+--- testing: 'abc' | 'a5.9' ---
+string(8) "61776f39"
+--- testing: '123abc' | '0' ---
+string(12) "313233616263"
+--- testing: '123abc' | '65' ---
+string(12) "373733616263"
+--- testing: '123abc' | '-44' ---
+string(12) "3d3637616263"
+--- testing: '123abc' | '1.2' ---
+string(12) "313e33616263"
+--- testing: '123abc' | '-7.7' ---
+string(12) "3d373f776263"
+--- testing: '123abc' | 'abc' ---
+string(12) "717273616263"
+--- testing: '123abc' | '123abc' ---
+string(12) "313233616263"
+--- testing: '123abc' | '123e5' ---
+string(12) "313233657763"
+--- testing: '123abc' | '123e5xyz' ---
+string(16) "31323365777b797a"
+--- testing: '123abc' | ' 123abc' ---
+string(14) "31333373636363"
+--- testing: '123abc' | '123 abc' ---
+string(14) "31323361636363"
+--- testing: '123abc' | '123abc ' ---
+string(14) "31323361626320"
+--- testing: '123abc' | '3.4a' ---
+string(12) "333e37616263"
+--- testing: '123abc' | 'a5.9' ---
+string(12) "71373f796263"
+--- testing: '123e5' | '0' ---
+string(10) "3132336535"
+--- testing: '123e5' | '65' ---
+string(10) "3737336535"
+--- testing: '123e5' | '-44' ---
+string(10) "3d36376535"
+--- testing: '123e5' | '1.2' ---
+string(10) "313e336535"
+--- testing: '123e5' | '-7.7' ---
+string(10) "3d373f7735"
+--- testing: '123e5' | 'abc' ---
+string(10) "7172736535"
+--- testing: '123e5' | '123abc' ---
+string(12) "313233657763"
+--- testing: '123e5' | '123e5' ---
+string(10) "3132336535"
+--- testing: '123e5' | '123e5xyz' ---
+string(16) "313233653578797a"
+--- testing: '123e5' | ' 123abc' ---
+string(14) "31333377756263"
+--- testing: '123e5' | '123 abc' ---
+string(14) "31323365756263"
+--- testing: '123e5' | '123abc ' ---
+string(14) "31323365776320"
+--- testing: '123e5' | '3.4a' ---
+string(10) "333e376535"
+--- testing: '123e5' | 'a5.9' ---
+string(10) "71373f7d35"
+--- testing: '123e5xyz' | '0' ---
+string(16) "313233653578797a"
+--- testing: '123e5xyz' | '65' ---
+string(16) "373733653578797a"
+--- testing: '123e5xyz' | '-44' ---
+string(16) "3d3637653578797a"
+--- testing: '123e5xyz' | '1.2' ---
+string(16) "313e33653578797a"
+--- testing: '123e5xyz' | '-7.7' ---
+string(16) "3d373f773578797a"
+--- testing: '123e5xyz' | 'abc' ---
+string(16) "717273653578797a"
+--- testing: '123e5xyz' | '123abc' ---
+string(16) "31323365777b797a"
+--- testing: '123e5xyz' | '123e5' ---
+string(16) "313233653578797a"
+--- testing: '123e5xyz' | '123e5xyz' ---
+string(16) "313233653578797a"
+--- testing: '123e5xyz' | ' 123abc' ---
+string(16) "31333377757a7b7a"
+--- testing: '123e5xyz' | '123 abc' ---
+string(16) "31323365757a7b7a"
+--- testing: '123e5xyz' | '123abc ' ---
+string(16) "31323365777b797a"
+--- testing: '123e5xyz' | '3.4a' ---
+string(16) "333e37653578797a"
+--- testing: '123e5xyz' | 'a5.9' ---
+string(16) "71373f7d3578797a"
+--- testing: ' 123abc' | '0' ---
+string(14) "30313233616263"
+--- testing: ' 123abc' | '65' ---
+string(14) "36353233616263"
+--- testing: ' 123abc' | '-44' ---
+string(14) "2d353633616263"
+--- testing: ' 123abc' | '1.2' ---
+string(14) "313f3233616263"
+--- testing: ' 123abc' | '-7.7' ---
+string(14) "2d373e37616263"
+--- testing: ' 123abc' | 'abc' ---
+string(14) "61737333616263"
+--- testing: ' 123abc' | '123abc' ---
+string(14) "31333373636363"
+--- testing: ' 123abc' | '123e5' ---
+string(14) "31333377756263"
+--- testing: ' 123abc' | '123e5xyz' ---
+string(16) "31333377757a7b7a"
+--- testing: ' 123abc' | ' 123abc' ---
+string(14) "20313233616263"
+--- testing: ' 123abc' | '123 abc' ---
+string(14) "31333333616263"
+--- testing: ' 123abc' | '123abc ' ---
+string(14) "31333373636363"
+--- testing: ' 123abc' | '3.4a' ---
+string(14) "333f3673616263"
+--- testing: ' 123abc' | 'a5.9' ---
+string(14) "61353e3b616263"
+--- testing: '123 abc' | '0' ---
+string(14) "31323320616263"
+--- testing: '123 abc' | '65' ---
+string(14) "37373320616263"
+--- testing: '123 abc' | '-44' ---
+string(14) "3d363720616263"
+--- testing: '123 abc' | '1.2' ---
+string(14) "313e3320616263"
+--- testing: '123 abc' | '-7.7' ---
+string(14) "3d373f37616263"
+--- testing: '123 abc' | 'abc' ---
+string(14) "71727320616263"
+--- testing: '123 abc' | '123abc' ---
+string(14) "31323361636363"
+--- testing: '123 abc' | '123e5' ---
+string(14) "31323365756263"
+--- testing: '123 abc' | '123e5xyz' ---
+string(16) "31323365757a7b7a"
+--- testing: '123 abc' | ' 123abc' ---
+string(14) "31333333616263"
+--- testing: '123 abc' | '123 abc' ---
+string(14) "31323320616263"
+--- testing: '123 abc' | '123abc ' ---
+string(14) "31323361636363"
+--- testing: '123 abc' | '3.4a' ---
+string(14) "333e3761616263"
+--- testing: '123 abc' | 'a5.9' ---
+string(14) "71373f39616263"
+--- testing: '123abc ' | '0' ---
+string(14) "31323361626320"
+--- testing: '123abc ' | '65' ---
+string(14) "37373361626320"
+--- testing: '123abc ' | '-44' ---
+string(14) "3d363761626320"
+--- testing: '123abc ' | '1.2' ---
+string(14) "313e3361626320"
+--- testing: '123abc ' | '-7.7' ---
+string(14) "3d373f77626320"
+--- testing: '123abc ' | 'abc' ---
+string(14) "71727361626320"
+--- testing: '123abc ' | '123abc' ---
+string(14) "31323361626320"
+--- testing: '123abc ' | '123e5' ---
+string(14) "31323365776320"
+--- testing: '123abc ' | '123e5xyz' ---
+string(16) "31323365777b797a"
+--- testing: '123abc ' | ' 123abc' ---
+string(14) "31333373636363"
+--- testing: '123abc ' | '123 abc' ---
+string(14) "31323361636363"
+--- testing: '123abc ' | '123abc ' ---
+string(14) "31323361626320"
+--- testing: '123abc ' | '3.4a' ---
+string(14) "333e3761626320"
+--- testing: '123abc ' | 'a5.9' ---
+string(14) "71373f79626320"
+--- testing: '3.4a' | '0' ---
+string(8) "332e3461"
+--- testing: '3.4a' | '65' ---
+string(8) "373f3461"
+--- testing: '3.4a' | '-44' ---
+string(8) "3f3e3461"
+--- testing: '3.4a' | '1.2' ---
+string(8) "332e3661"
+--- testing: '3.4a' | '-7.7' ---
+string(8) "3f3f3e77"
+--- testing: '3.4a' | 'abc' ---
+string(8) "736e7761"
+--- testing: '3.4a' | '123abc' ---
+string(12) "333e37616263"
+--- testing: '3.4a' | '123e5' ---
+string(10) "333e376535"
+--- testing: '3.4a' | '123e5xyz' ---
+string(16) "333e37653578797a"
+--- testing: '3.4a' | ' 123abc' ---
+string(14) "333f3673616263"
+--- testing: '3.4a' | '123 abc' ---
+string(14) "333e3761616263"
+--- testing: '3.4a' | '123abc ' ---
+string(14) "333e3761626320"
+--- testing: '3.4a' | '3.4a' ---
+string(8) "332e3461"
+--- testing: '3.4a' | 'a5.9' ---
+string(8) "733f3e79"
+--- testing: 'a5.9' | '0' ---
+string(8) "71352e39"
+--- testing: 'a5.9' | '65' ---
+string(8) "77352e39"
+--- testing: 'a5.9' | '-44' ---
+string(8) "6d353e39"
+--- testing: 'a5.9' | '1.2' ---
+string(8) "713f3e39"
+--- testing: 'a5.9' | '-7.7' ---
+string(8) "6d372e3f"
+--- testing: 'a5.9' | 'abc' ---
+string(8) "61776f39"
+--- testing: 'a5.9' | '123abc' ---
+string(12) "71373f796263"
+--- testing: 'a5.9' | '123e5' ---
+string(10) "71373f7d35"
+--- testing: 'a5.9' | '123e5xyz' ---
+string(16) "71373f7d3578797a"
+--- testing: 'a5.9' | ' 123abc' ---
+string(14) "61353e3b616263"
+--- testing: 'a5.9' | '123 abc' ---
+string(14) "71373f39616263"
+--- testing: 'a5.9' | '123abc ' ---
+string(14) "71373f79626320"
+--- testing: 'a5.9' | '3.4a' ---
+string(8) "733f3e79"
+--- testing: 'a5.9' | 'a5.9' ---
+string(8) "61352e39"
+===DONE===
diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
new file mode 100644
index 0000000000..b1bc437b0f
--- /dev/null
+++ b/tests/lang/operators/bitwiseShiftLeft_variationStr.phpt
@@ -0,0 +1,421 @@
+--TEST--
+Test << operator : various numbers as strings
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' << '$otherVal' ---\n";
+ var_dump(bin2hex($strVal<<$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' << '0' ---
+string(2) "30"
+--- testing: '0' << '65' ---
+string(2) "30"
+--- testing: '0' << '-44' ---
+string(2) "30"
+--- testing: '0' << '1.2' ---
+string(2) "30"
+--- testing: '0' << '-7.7' ---
+string(2) "30"
+--- testing: '0' << 'abc' ---
+string(2) "30"
+--- testing: '0' << '123abc' ---
+string(2) "30"
+--- testing: '0' << '123e5' ---
+string(2) "30"
+--- testing: '0' << '123e5xyz' ---
+string(2) "30"
+--- testing: '0' << ' 123abc' ---
+string(2) "30"
+--- testing: '0' << '123 abc' ---
+string(2) "30"
+--- testing: '0' << '123abc ' ---
+string(2) "30"
+--- testing: '0' << '3.4a' ---
+string(2) "30"
+--- testing: '0' << 'a5.9' ---
+string(2) "30"
+--- testing: '65' << '0' ---
+string(4) "3635"
+--- testing: '65' << '65' ---
+string(6) "313330"
+--- testing: '65' << '-44' ---
+string(16) "3638313537343430"
+--- testing: '65' << '1.2' ---
+string(6) "313330"
+--- testing: '65' << '-7.7' ---
+string(22) "2d32313133393239323136"
+--- testing: '65' << 'abc' ---
+string(4) "3635"
+--- testing: '65' << '123abc' ---
+string(18) "313334323137373238"
+--- testing: '65' << '123e5' ---
+string(18) "313334323137373238"
+--- testing: '65' << '123e5xyz' ---
+string(18) "313334323137373238"
+--- testing: '65' << ' 123abc' ---
+string(18) "313334323137373238"
+--- testing: '65' << '123 abc' ---
+string(18) "313334323137373238"
+--- testing: '65' << '123abc ' ---
+string(18) "313334323137373238"
+--- testing: '65' << '3.4a' ---
+string(6) "353230"
+--- testing: '65' << 'a5.9' ---
+string(4) "3635"
+--- testing: '-44' << '0' ---
+string(6) "2d3434"
+--- testing: '-44' << '65' ---
+string(6) "2d3838"
+--- testing: '-44' << '-44' ---
+string(18) "2d3436313337333434"
+--- testing: '-44' << '1.2' ---
+string(6) "2d3838"
+--- testing: '-44' << '-7.7' ---
+string(22) "2d31343736333935303038"
+--- testing: '-44' << 'abc' ---
+string(6) "2d3434"
+--- testing: '-44' << '123abc' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << '123e5' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << '123e5xyz' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << ' 123abc' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << '123 abc' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << '123abc ' ---
+string(22) "2d31363130363132373336"
+--- testing: '-44' << '3.4a' ---
+string(8) "2d333532"
+--- testing: '-44' << 'a5.9' ---
+string(6) "2d3434"
+--- testing: '1.2' << '0' ---
+string(2) "31"
+--- testing: '1.2' << '65' ---
+string(2) "32"
+--- testing: '1.2' << '-44' ---
+string(14) "31303438353736"
+--- testing: '1.2' << '1.2' ---
+string(2) "32"
+--- testing: '1.2' << '-7.7' ---
+string(16) "3333353534343332"
+--- testing: '1.2' << 'abc' ---
+string(2) "31"
+--- testing: '1.2' << '123abc' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << '123e5' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << '123e5xyz' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << ' 123abc' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << '123 abc' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << '123abc ' ---
+string(18) "313334323137373238"
+--- testing: '1.2' << '3.4a' ---
+string(2) "38"
+--- testing: '1.2' << 'a5.9' ---
+string(2) "31"
+--- testing: '-7.7' << '0' ---
+string(4) "2d37"
+--- testing: '-7.7' << '65' ---
+string(6) "2d3134"
+--- testing: '-7.7' << '-44' ---
+string(16) "2d37333430303332"
+--- testing: '-7.7' << '1.2' ---
+string(6) "2d3134"
+--- testing: '-7.7' << '-7.7' ---
+string(20) "2d323334383831303234"
+--- testing: '-7.7' << 'abc' ---
+string(4) "2d37"
+--- testing: '-7.7' << '123abc' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << '123e5' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << '123e5xyz' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << ' 123abc' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << '123 abc' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << '123abc ' ---
+string(20) "2d393339353234303936"
+--- testing: '-7.7' << '3.4a' ---
+string(6) "2d3536"
+--- testing: '-7.7' << 'a5.9' ---
+string(4) "2d37"
+--- testing: 'abc' << '0' ---
+string(2) "30"
+--- testing: 'abc' << '65' ---
+string(2) "30"
+--- testing: 'abc' << '-44' ---
+string(2) "30"
+--- testing: 'abc' << '1.2' ---
+string(2) "30"
+--- testing: 'abc' << '-7.7' ---
+string(2) "30"
+--- testing: 'abc' << 'abc' ---
+string(2) "30"
+--- testing: 'abc' << '123abc' ---
+string(2) "30"
+--- testing: 'abc' << '123e5' ---
+string(2) "30"
+--- testing: 'abc' << '123e5xyz' ---
+string(2) "30"
+--- testing: 'abc' << ' 123abc' ---
+string(2) "30"
+--- testing: 'abc' << '123 abc' ---
+string(2) "30"
+--- testing: 'abc' << '123abc ' ---
+string(2) "30"
+--- testing: 'abc' << '3.4a' ---
+string(2) "30"
+--- testing: 'abc' << 'a5.9' ---
+string(2) "30"
+--- testing: '123abc' << '0' ---
+string(6) "313233"
+--- testing: '123abc' << '65' ---
+string(6) "323436"
+--- testing: '123abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123abc' << '1.2' ---
+string(6) "323436"
+--- testing: '123abc' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: '123abc' << 'abc' ---
+string(6) "313233"
+--- testing: '123abc' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc' << '3.4a' ---
+string(6) "393834"
+--- testing: '123abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5' << '0' ---
+string(6) "313233"
+--- testing: '123e5' << '65' ---
+string(6) "323436"
+--- testing: '123e5' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123e5' << '1.2' ---
+string(6) "323436"
+--- testing: '123e5' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: '123e5' << 'abc' ---
+string(6) "313233"
+--- testing: '123e5' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5' << '3.4a' ---
+string(6) "393834"
+--- testing: '123e5' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '0' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '65' ---
+string(6) "323436"
+--- testing: '123e5xyz' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123e5xyz' << '1.2' ---
+string(6) "323436"
+--- testing: '123e5xyz' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: '123e5xyz' << 'abc' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: '123e5xyz' << '3.4a' ---
+string(6) "393834"
+--- testing: '123e5xyz' << 'a5.9' ---
+string(6) "313233"
+--- testing: ' 123abc' << '0' ---
+string(6) "313233"
+--- testing: ' 123abc' << '65' ---
+string(6) "323436"
+--- testing: ' 123abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: ' 123abc' << '1.2' ---
+string(6) "323436"
+--- testing: ' 123abc' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: ' 123abc' << 'abc' ---
+string(6) "313233"
+--- testing: ' 123abc' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: ' 123abc' << '3.4a' ---
+string(6) "393834"
+--- testing: ' 123abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123 abc' << '0' ---
+string(6) "313233"
+--- testing: '123 abc' << '65' ---
+string(6) "323436"
+--- testing: '123 abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123 abc' << '1.2' ---
+string(6) "323436"
+--- testing: '123 abc' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: '123 abc' << 'abc' ---
+string(6) "313233"
+--- testing: '123 abc' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: '123 abc' << '3.4a' ---
+string(6) "393834"
+--- testing: '123 abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123abc ' << '0' ---
+string(6) "313233"
+--- testing: '123abc ' << '65' ---
+string(6) "323436"
+--- testing: '123abc ' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123abc ' << '1.2' ---
+string(6) "323436"
+--- testing: '123abc ' << '-7.7' ---
+string(20) "2d313637373732313630"
+--- testing: '123abc ' << 'abc' ---
+string(6) "313233"
+--- testing: '123abc ' << '123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << '123e5' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << '123e5xyz' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << ' 123abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << '123 abc' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << '123abc ' ---
+string(20) "2d363731303838363430"
+--- testing: '123abc ' << '3.4a' ---
+string(6) "393834"
+--- testing: '123abc ' << 'a5.9' ---
+string(6) "313233"
+--- testing: '3.4a' << '0' ---
+string(2) "33"
+--- testing: '3.4a' << '65' ---
+string(2) "36"
+--- testing: '3.4a' << '-44' ---
+string(14) "33313435373238"
+--- testing: '3.4a' << '1.2' ---
+string(2) "36"
+--- testing: '3.4a' << '-7.7' ---
+string(18) "313030363633323936"
+--- testing: '3.4a' << 'abc' ---
+string(2) "33"
+--- testing: '3.4a' << '123abc' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << '123e5' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << '123e5xyz' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << ' 123abc' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << '123 abc' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << '123abc ' ---
+string(18) "343032363533313834"
+--- testing: '3.4a' << '3.4a' ---
+string(4) "3234"
+--- testing: '3.4a' << 'a5.9' ---
+string(2) "33"
+--- testing: 'a5.9' << '0' ---
+string(2) "30"
+--- testing: 'a5.9' << '65' ---
+string(2) "30"
+--- testing: 'a5.9' << '-44' ---
+string(2) "30"
+--- testing: 'a5.9' << '1.2' ---
+string(2) "30"
+--- testing: 'a5.9' << '-7.7' ---
+string(2) "30"
+--- testing: 'a5.9' << 'abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123e5' ---
+string(2) "30"
+--- testing: 'a5.9' << '123e5xyz' ---
+string(2) "30"
+--- testing: 'a5.9' << ' 123abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123 abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123abc ' ---
+string(2) "30"
+--- testing: 'a5.9' << '3.4a' ---
+string(2) "30"
+--- testing: 'a5.9' << 'a5.9' ---
+string(2) "30"
+===DONE===
+
diff --git a/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt
new file mode 100644
index 0000000000..0b697c8579
--- /dev/null
+++ b/tests/lang/operators/bitwiseShiftLeft_variationStr_64bit.phpt
@@ -0,0 +1,420 @@
+--TEST--
+Test << operator : various numbers as strings
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' << '$otherVal' ---\n";
+ var_dump(bin2hex($strVal<<$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' << '0' ---
+string(2) "30"
+--- testing: '0' << '65' ---
+string(2) "30"
+--- testing: '0' << '-44' ---
+string(2) "30"
+--- testing: '0' << '1.2' ---
+string(2) "30"
+--- testing: '0' << '-7.7' ---
+string(2) "30"
+--- testing: '0' << 'abc' ---
+string(2) "30"
+--- testing: '0' << '123abc' ---
+string(2) "30"
+--- testing: '0' << '123e5' ---
+string(2) "30"
+--- testing: '0' << '123e5xyz' ---
+string(2) "30"
+--- testing: '0' << ' 123abc' ---
+string(2) "30"
+--- testing: '0' << '123 abc' ---
+string(2) "30"
+--- testing: '0' << '123abc ' ---
+string(2) "30"
+--- testing: '0' << '3.4a' ---
+string(2) "30"
+--- testing: '0' << 'a5.9' ---
+string(2) "30"
+--- testing: '65' << '0' ---
+string(4) "3635"
+--- testing: '65' << '65' ---
+string(6) "313330"
+--- testing: '65' << '-44' ---
+string(16) "3638313537343430"
+--- testing: '65' << '1.2' ---
+string(6) "313330"
+--- testing: '65' << '-7.7' ---
+string(40) "2d39303739323536383438373738393139393336"
+--- testing: '65' << 'abc' ---
+string(4) "3635"
+--- testing: '65' << '123abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << '123e5' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << '123e5xyz' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << ' 123abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << '123 abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << '123abc ' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '65' << '3.4a' ---
+string(6) "353230"
+--- testing: '65' << 'a5.9' ---
+string(4) "3635"
+--- testing: '-44' << '0' ---
+string(6) "2d3434"
+--- testing: '-44' << '65' ---
+string(6) "2d3838"
+--- testing: '-44' << '-44' ---
+string(18) "2d3436313337333434"
+--- testing: '-44' << '1.2' ---
+string(6) "2d3838"
+--- testing: '-44' << '-7.7' ---
+string(40) "2d36333431303638323735333337363538333638"
+--- testing: '-44' << 'abc' ---
+string(6) "2d3434"
+--- testing: '-44' << '123abc' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << '123e5' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << '123e5xyz' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << ' 123abc' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << '123 abc' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << '123abc ' ---
+string(40) "2d36393137353239303237363431303831383536"
+--- testing: '-44' << '3.4a' ---
+string(8) "2d333532"
+--- testing: '-44' << 'a5.9' ---
+string(6) "2d3434"
+--- testing: '1.2' << '0' ---
+string(2) "31"
+--- testing: '1.2' << '65' ---
+string(2) "32"
+--- testing: '1.2' << '-44' ---
+string(14) "31303438353736"
+--- testing: '1.2' << '1.2' ---
+string(2) "32"
+--- testing: '1.2' << '-7.7' ---
+string(36) "313434313135313838303735383535383732"
+--- testing: '1.2' << 'abc' ---
+string(2) "31"
+--- testing: '1.2' << '123abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << '123e5' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << '123e5xyz' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << ' 123abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << '123 abc' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << '123abc ' ---
+string(36) "353736343630373532333033343233343838"
+--- testing: '1.2' << '3.4a' ---
+string(2) "38"
+--- testing: '1.2' << 'a5.9' ---
+string(2) "31"
+--- testing: '-7.7' << '0' ---
+string(4) "2d37"
+--- testing: '-7.7' << '65' ---
+string(6) "2d3134"
+--- testing: '-7.7' << '-44' ---
+string(16) "2d37333430303332"
+--- testing: '-7.7' << '1.2' ---
+string(6) "2d3134"
+--- testing: '-7.7' << '-7.7' ---
+string(40) "2d31303038383036333136353330393931313034"
+--- testing: '-7.7' << 'abc' ---
+string(4) "2d37"
+--- testing: '-7.7' << '123abc' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << '123e5' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << '123e5xyz' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << ' 123abc' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << '123 abc' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << '123abc ' ---
+string(40) "2d34303335323235323636313233393634343136"
+--- testing: '-7.7' << '3.4a' ---
+string(6) "2d3536"
+--- testing: '-7.7' << 'a5.9' ---
+string(4) "2d37"
+--- testing: 'abc' << '0' ---
+string(2) "30"
+--- testing: 'abc' << '65' ---
+string(2) "30"
+--- testing: 'abc' << '-44' ---
+string(2) "30"
+--- testing: 'abc' << '1.2' ---
+string(2) "30"
+--- testing: 'abc' << '-7.7' ---
+string(2) "30"
+--- testing: 'abc' << 'abc' ---
+string(2) "30"
+--- testing: 'abc' << '123abc' ---
+string(2) "30"
+--- testing: 'abc' << '123e5' ---
+string(2) "30"
+--- testing: 'abc' << '123e5xyz' ---
+string(2) "30"
+--- testing: 'abc' << ' 123abc' ---
+string(2) "30"
+--- testing: 'abc' << '123 abc' ---
+string(2) "30"
+--- testing: 'abc' << '123abc ' ---
+string(2) "30"
+--- testing: 'abc' << '3.4a' ---
+string(2) "30"
+--- testing: 'abc' << 'a5.9' ---
+string(2) "30"
+--- testing: '123abc' << '0' ---
+string(6) "313233"
+--- testing: '123abc' << '65' ---
+string(6) "323436"
+--- testing: '123abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123abc' << '1.2' ---
+string(6) "323436"
+--- testing: '123abc' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: '123abc' << 'abc' ---
+string(6) "313233"
+--- testing: '123abc' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc' << '3.4a' ---
+string(6) "393834"
+--- testing: '123abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5' << '0' ---
+string(6) "313233"
+--- testing: '123e5' << '65' ---
+string(6) "323436"
+--- testing: '123e5' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123e5' << '1.2' ---
+string(6) "323436"
+--- testing: '123e5' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: '123e5' << 'abc' ---
+string(6) "313233"
+--- testing: '123e5' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5' << '3.4a' ---
+string(6) "393834"
+--- testing: '123e5' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '0' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '65' ---
+string(6) "323436"
+--- testing: '123e5xyz' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123e5xyz' << '1.2' ---
+string(6) "323436"
+--- testing: '123e5xyz' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: '123e5xyz' << 'abc' ---
+string(6) "313233"
+--- testing: '123e5xyz' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123e5xyz' << '3.4a' ---
+string(6) "393834"
+--- testing: '123e5xyz' << 'a5.9' ---
+string(6) "313233"
+--- testing: ' 123abc' << '0' ---
+string(6) "313233"
+--- testing: ' 123abc' << '65' ---
+string(6) "323436"
+--- testing: ' 123abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: ' 123abc' << '1.2' ---
+string(6) "323436"
+--- testing: ' 123abc' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: ' 123abc' << 'abc' ---
+string(6) "313233"
+--- testing: ' 123abc' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: ' 123abc' << '3.4a' ---
+string(6) "393834"
+--- testing: ' 123abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123 abc' << '0' ---
+string(6) "313233"
+--- testing: '123 abc' << '65' ---
+string(6) "323436"
+--- testing: '123 abc' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123 abc' << '1.2' ---
+string(6) "323436"
+--- testing: '123 abc' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: '123 abc' << 'abc' ---
+string(6) "313233"
+--- testing: '123 abc' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123 abc' << '3.4a' ---
+string(6) "393834"
+--- testing: '123 abc' << 'a5.9' ---
+string(6) "313233"
+--- testing: '123abc ' << '0' ---
+string(6) "313233"
+--- testing: '123abc ' << '65' ---
+string(6) "323436"
+--- testing: '123abc ' << '-44' ---
+string(18) "313238393734383438"
+--- testing: '123abc ' << '1.2' ---
+string(6) "323436"
+--- testing: '123abc ' << '-7.7' ---
+string(38) "2d373230353735393430333739323739333630"
+--- testing: '123abc ' << 'abc' ---
+string(6) "313233"
+--- testing: '123abc ' << '123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << '123e5' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << '123e5xyz' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << ' 123abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << '123 abc' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << '123abc ' ---
+string(40) "2d32383832333033373631353137313137343430"
+--- testing: '123abc ' << '3.4a' ---
+string(6) "393834"
+--- testing: '123abc ' << 'a5.9' ---
+string(6) "313233"
+--- testing: '3.4a' << '0' ---
+string(2) "33"
+--- testing: '3.4a' << '65' ---
+string(2) "36"
+--- testing: '3.4a' << '-44' ---
+string(14) "33313435373238"
+--- testing: '3.4a' << '1.2' ---
+string(2) "36"
+--- testing: '3.4a' << '-7.7' ---
+string(36) "343332333435353634323237353637363136"
+--- testing: '3.4a' << 'abc' ---
+string(2) "33"
+--- testing: '3.4a' << '123abc' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << '123e5' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << '123e5xyz' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << ' 123abc' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << '123 abc' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << '123abc ' ---
+string(38) "31373239333832323536393130323730343634"
+--- testing: '3.4a' << '3.4a' ---
+string(4) "3234"
+--- testing: '3.4a' << 'a5.9' ---
+string(2) "33"
+--- testing: 'a5.9' << '0' ---
+string(2) "30"
+--- testing: 'a5.9' << '65' ---
+string(2) "30"
+--- testing: 'a5.9' << '-44' ---
+string(2) "30"
+--- testing: 'a5.9' << '1.2' ---
+string(2) "30"
+--- testing: 'a5.9' << '-7.7' ---
+string(2) "30"
+--- testing: 'a5.9' << 'abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123e5' ---
+string(2) "30"
+--- testing: 'a5.9' << '123e5xyz' ---
+string(2) "30"
+--- testing: 'a5.9' << ' 123abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123 abc' ---
+string(2) "30"
+--- testing: 'a5.9' << '123abc ' ---
+string(2) "30"
+--- testing: 'a5.9' << '3.4a' ---
+string(2) "30"
+--- testing: 'a5.9' << 'a5.9' ---
+string(2) "30"
+===DONE===
diff --git a/tests/lang/operators/bitwiseShiftRight_variationStr.phpt b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt
new file mode 100644
index 0000000000..9518d42cdc
--- /dev/null
+++ b/tests/lang/operators/bitwiseShiftRight_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test >> operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' >> '$otherVal' ---\n";
+ var_dump(bin2hex($strVal>>$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' >> '0' ---
+string(2) "30"
+--- testing: '0' >> '65' ---
+string(2) "30"
+--- testing: '0' >> '-44' ---
+string(2) "30"
+--- testing: '0' >> '1.2' ---
+string(2) "30"
+--- testing: '0' >> '-7.7' ---
+string(2) "30"
+--- testing: '0' >> 'abc' ---
+string(2) "30"
+--- testing: '0' >> '123abc' ---
+string(2) "30"
+--- testing: '0' >> '123e5' ---
+string(2) "30"
+--- testing: '0' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '0' >> ' 123abc' ---
+string(2) "30"
+--- testing: '0' >> '123 abc' ---
+string(2) "30"
+--- testing: '0' >> '123abc ' ---
+string(2) "30"
+--- testing: '0' >> '3.4a' ---
+string(2) "30"
+--- testing: '0' >> 'a5.9' ---
+string(2) "30"
+--- testing: '65' >> '0' ---
+string(4) "3635"
+--- testing: '65' >> '65' ---
+string(4) "3332"
+--- testing: '65' >> '-44' ---
+string(2) "30"
+--- testing: '65' >> '1.2' ---
+string(4) "3332"
+--- testing: '65' >> '-7.7' ---
+string(2) "30"
+--- testing: '65' >> 'abc' ---
+string(4) "3635"
+--- testing: '65' >> '123abc' ---
+string(2) "30"
+--- testing: '65' >> '123e5' ---
+string(2) "30"
+--- testing: '65' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '65' >> ' 123abc' ---
+string(2) "30"
+--- testing: '65' >> '123 abc' ---
+string(2) "30"
+--- testing: '65' >> '123abc ' ---
+string(2) "30"
+--- testing: '65' >> '3.4a' ---
+string(2) "38"
+--- testing: '65' >> 'a5.9' ---
+string(4) "3635"
+--- testing: '-44' >> '0' ---
+string(6) "2d3434"
+--- testing: '-44' >> '65' ---
+string(6) "2d3232"
+--- testing: '-44' >> '-44' ---
+string(4) "2d31"
+--- testing: '-44' >> '1.2' ---
+string(6) "2d3232"
+--- testing: '-44' >> '-7.7' ---
+string(4) "2d31"
+--- testing: '-44' >> 'abc' ---
+string(6) "2d3434"
+--- testing: '-44' >> '123abc' ---
+string(4) "2d31"
+--- testing: '-44' >> '123e5' ---
+string(4) "2d31"
+--- testing: '-44' >> '123e5xyz' ---
+string(4) "2d31"
+--- testing: '-44' >> ' 123abc' ---
+string(4) "2d31"
+--- testing: '-44' >> '123 abc' ---
+string(4) "2d31"
+--- testing: '-44' >> '123abc ' ---
+string(4) "2d31"
+--- testing: '-44' >> '3.4a' ---
+string(4) "2d36"
+--- testing: '-44' >> 'a5.9' ---
+string(6) "2d3434"
+--- testing: '1.2' >> '0' ---
+string(2) "31"
+--- testing: '1.2' >> '65' ---
+string(2) "30"
+--- testing: '1.2' >> '-44' ---
+string(2) "30"
+--- testing: '1.2' >> '1.2' ---
+string(2) "30"
+--- testing: '1.2' >> '-7.7' ---
+string(2) "30"
+--- testing: '1.2' >> 'abc' ---
+string(2) "31"
+--- testing: '1.2' >> '123abc' ---
+string(2) "30"
+--- testing: '1.2' >> '123e5' ---
+string(2) "30"
+--- testing: '1.2' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '1.2' >> ' 123abc' ---
+string(2) "30"
+--- testing: '1.2' >> '123 abc' ---
+string(2) "30"
+--- testing: '1.2' >> '123abc ' ---
+string(2) "30"
+--- testing: '1.2' >> '3.4a' ---
+string(2) "30"
+--- testing: '1.2' >> 'a5.9' ---
+string(2) "31"
+--- testing: '-7.7' >> '0' ---
+string(4) "2d37"
+--- testing: '-7.7' >> '65' ---
+string(4) "2d34"
+--- testing: '-7.7' >> '-44' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '1.2' ---
+string(4) "2d34"
+--- testing: '-7.7' >> '-7.7' ---
+string(4) "2d31"
+--- testing: '-7.7' >> 'abc' ---
+string(4) "2d37"
+--- testing: '-7.7' >> '123abc' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '123e5' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '123e5xyz' ---
+string(4) "2d31"
+--- testing: '-7.7' >> ' 123abc' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '123 abc' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '123abc ' ---
+string(4) "2d31"
+--- testing: '-7.7' >> '3.4a' ---
+string(4) "2d31"
+--- testing: '-7.7' >> 'a5.9' ---
+string(4) "2d37"
+--- testing: 'abc' >> '0' ---
+string(2) "30"
+--- testing: 'abc' >> '65' ---
+string(2) "30"
+--- testing: 'abc' >> '-44' ---
+string(2) "30"
+--- testing: 'abc' >> '1.2' ---
+string(2) "30"
+--- testing: 'abc' >> '-7.7' ---
+string(2) "30"
+--- testing: 'abc' >> 'abc' ---
+string(2) "30"
+--- testing: 'abc' >> '123abc' ---
+string(2) "30"
+--- testing: 'abc' >> '123e5' ---
+string(2) "30"
+--- testing: 'abc' >> '123e5xyz' ---
+string(2) "30"
+--- testing: 'abc' >> ' 123abc' ---
+string(2) "30"
+--- testing: 'abc' >> '123 abc' ---
+string(2) "30"
+--- testing: 'abc' >> '123abc ' ---
+string(2) "30"
+--- testing: 'abc' >> '3.4a' ---
+string(2) "30"
+--- testing: 'abc' >> 'a5.9' ---
+string(2) "30"
+--- testing: '123abc' >> '0' ---
+string(6) "313233"
+--- testing: '123abc' >> '65' ---
+string(4) "3631"
+--- testing: '123abc' >> '-44' ---
+string(2) "30"
+--- testing: '123abc' >> '1.2' ---
+string(4) "3631"
+--- testing: '123abc' >> '-7.7' ---
+string(2) "30"
+--- testing: '123abc' >> 'abc' ---
+string(6) "313233"
+--- testing: '123abc' >> '123abc' ---
+string(2) "30"
+--- testing: '123abc' >> '123e5' ---
+string(2) "30"
+--- testing: '123abc' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '123abc' >> ' 123abc' ---
+string(2) "30"
+--- testing: '123abc' >> '123 abc' ---
+string(2) "30"
+--- testing: '123abc' >> '123abc ' ---
+string(2) "30"
+--- testing: '123abc' >> '3.4a' ---
+string(4) "3135"
+--- testing: '123abc' >> 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5' >> '0' ---
+string(6) "313233"
+--- testing: '123e5' >> '65' ---
+string(4) "3631"
+--- testing: '123e5' >> '-44' ---
+string(2) "30"
+--- testing: '123e5' >> '1.2' ---
+string(4) "3631"
+--- testing: '123e5' >> '-7.7' ---
+string(2) "30"
+--- testing: '123e5' >> 'abc' ---
+string(6) "313233"
+--- testing: '123e5' >> '123abc' ---
+string(2) "30"
+--- testing: '123e5' >> '123e5' ---
+string(2) "30"
+--- testing: '123e5' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '123e5' >> ' 123abc' ---
+string(2) "30"
+--- testing: '123e5' >> '123 abc' ---
+string(2) "30"
+--- testing: '123e5' >> '123abc ' ---
+string(2) "30"
+--- testing: '123e5' >> '3.4a' ---
+string(4) "3135"
+--- testing: '123e5' >> 'a5.9' ---
+string(6) "313233"
+--- testing: '123e5xyz' >> '0' ---
+string(6) "313233"
+--- testing: '123e5xyz' >> '65' ---
+string(4) "3631"
+--- testing: '123e5xyz' >> '-44' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '1.2' ---
+string(4) "3631"
+--- testing: '123e5xyz' >> '-7.7' ---
+string(2) "30"
+--- testing: '123e5xyz' >> 'abc' ---
+string(6) "313233"
+--- testing: '123e5xyz' >> '123abc' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '123e5' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '123e5xyz' >> ' 123abc' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '123 abc' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '123abc ' ---
+string(2) "30"
+--- testing: '123e5xyz' >> '3.4a' ---
+string(4) "3135"
+--- testing: '123e5xyz' >> 'a5.9' ---
+string(6) "313233"
+--- testing: ' 123abc' >> '0' ---
+string(6) "313233"
+--- testing: ' 123abc' >> '65' ---
+string(4) "3631"
+--- testing: ' 123abc' >> '-44' ---
+string(2) "30"
+--- testing: ' 123abc' >> '1.2' ---
+string(4) "3631"
+--- testing: ' 123abc' >> '-7.7' ---
+string(2) "30"
+--- testing: ' 123abc' >> 'abc' ---
+string(6) "313233"
+--- testing: ' 123abc' >> '123abc' ---
+string(2) "30"
+--- testing: ' 123abc' >> '123e5' ---
+string(2) "30"
+--- testing: ' 123abc' >> '123e5xyz' ---
+string(2) "30"
+--- testing: ' 123abc' >> ' 123abc' ---
+string(2) "30"
+--- testing: ' 123abc' >> '123 abc' ---
+string(2) "30"
+--- testing: ' 123abc' >> '123abc ' ---
+string(2) "30"
+--- testing: ' 123abc' >> '3.4a' ---
+string(4) "3135"
+--- testing: ' 123abc' >> 'a5.9' ---
+string(6) "313233"
+--- testing: '123 abc' >> '0' ---
+string(6) "313233"
+--- testing: '123 abc' >> '65' ---
+string(4) "3631"
+--- testing: '123 abc' >> '-44' ---
+string(2) "30"
+--- testing: '123 abc' >> '1.2' ---
+string(4) "3631"
+--- testing: '123 abc' >> '-7.7' ---
+string(2) "30"
+--- testing: '123 abc' >> 'abc' ---
+string(6) "313233"
+--- testing: '123 abc' >> '123abc' ---
+string(2) "30"
+--- testing: '123 abc' >> '123e5' ---
+string(2) "30"
+--- testing: '123 abc' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '123 abc' >> ' 123abc' ---
+string(2) "30"
+--- testing: '123 abc' >> '123 abc' ---
+string(2) "30"
+--- testing: '123 abc' >> '123abc ' ---
+string(2) "30"
+--- testing: '123 abc' >> '3.4a' ---
+string(4) "3135"
+--- testing: '123 abc' >> 'a5.9' ---
+string(6) "313233"
+--- testing: '123abc ' >> '0' ---
+string(6) "313233"
+--- testing: '123abc ' >> '65' ---
+string(4) "3631"
+--- testing: '123abc ' >> '-44' ---
+string(2) "30"
+--- testing: '123abc ' >> '1.2' ---
+string(4) "3631"
+--- testing: '123abc ' >> '-7.7' ---
+string(2) "30"
+--- testing: '123abc ' >> 'abc' ---
+string(6) "313233"
+--- testing: '123abc ' >> '123abc' ---
+string(2) "30"
+--- testing: '123abc ' >> '123e5' ---
+string(2) "30"
+--- testing: '123abc ' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '123abc ' >> ' 123abc' ---
+string(2) "30"
+--- testing: '123abc ' >> '123 abc' ---
+string(2) "30"
+--- testing: '123abc ' >> '123abc ' ---
+string(2) "30"
+--- testing: '123abc ' >> '3.4a' ---
+string(4) "3135"
+--- testing: '123abc ' >> 'a5.9' ---
+string(6) "313233"
+--- testing: '3.4a' >> '0' ---
+string(2) "33"
+--- testing: '3.4a' >> '65' ---
+string(2) "31"
+--- testing: '3.4a' >> '-44' ---
+string(2) "30"
+--- testing: '3.4a' >> '1.2' ---
+string(2) "31"
+--- testing: '3.4a' >> '-7.7' ---
+string(2) "30"
+--- testing: '3.4a' >> 'abc' ---
+string(2) "33"
+--- testing: '3.4a' >> '123abc' ---
+string(2) "30"
+--- testing: '3.4a' >> '123e5' ---
+string(2) "30"
+--- testing: '3.4a' >> '123e5xyz' ---
+string(2) "30"
+--- testing: '3.4a' >> ' 123abc' ---
+string(2) "30"
+--- testing: '3.4a' >> '123 abc' ---
+string(2) "30"
+--- testing: '3.4a' >> '123abc ' ---
+string(2) "30"
+--- testing: '3.4a' >> '3.4a' ---
+string(2) "30"
+--- testing: '3.4a' >> 'a5.9' ---
+string(2) "33"
+--- testing: 'a5.9' >> '0' ---
+string(2) "30"
+--- testing: 'a5.9' >> '65' ---
+string(2) "30"
+--- testing: 'a5.9' >> '-44' ---
+string(2) "30"
+--- testing: 'a5.9' >> '1.2' ---
+string(2) "30"
+--- testing: 'a5.9' >> '-7.7' ---
+string(2) "30"
+--- testing: 'a5.9' >> 'abc' ---
+string(2) "30"
+--- testing: 'a5.9' >> '123abc' ---
+string(2) "30"
+--- testing: 'a5.9' >> '123e5' ---
+string(2) "30"
+--- testing: 'a5.9' >> '123e5xyz' ---
+string(2) "30"
+--- testing: 'a5.9' >> ' 123abc' ---
+string(2) "30"
+--- testing: 'a5.9' >> '123 abc' ---
+string(2) "30"
+--- testing: 'a5.9' >> '123abc ' ---
+string(2) "30"
+--- testing: 'a5.9' >> '3.4a' ---
+string(2) "30"
+--- testing: 'a5.9' >> 'a5.9' ---
+string(2) "30"
+===DONE===
diff --git a/tests/lang/operators/bitwiseXor_variationStr.phpt b/tests/lang/operators/bitwiseXor_variationStr.phpt
new file mode 100644
index 0000000000..7dda65910a
--- /dev/null
+++ b/tests/lang/operators/bitwiseXor_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test ^ operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' ^ '$otherVal' ---\n";
+ var_dump(bin2hex($strVal^$otherVal));
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ^ '0' ---
+string(2) "00"
+--- testing: '0' ^ '65' ---
+string(2) "06"
+--- testing: '0' ^ '-44' ---
+string(2) "1d"
+--- testing: '0' ^ '1.2' ---
+string(2) "01"
+--- testing: '0' ^ '-7.7' ---
+string(2) "1d"
+--- testing: '0' ^ 'abc' ---
+string(2) "51"
+--- testing: '0' ^ '123abc' ---
+string(2) "01"
+--- testing: '0' ^ '123e5' ---
+string(2) "01"
+--- testing: '0' ^ '123e5xyz' ---
+string(2) "01"
+--- testing: '0' ^ ' 123abc' ---
+string(2) "10"
+--- testing: '0' ^ '123 abc' ---
+string(2) "01"
+--- testing: '0' ^ '123abc ' ---
+string(2) "01"
+--- testing: '0' ^ '3.4a' ---
+string(2) "03"
+--- testing: '0' ^ 'a5.9' ---
+string(2) "51"
+--- testing: '65' ^ '0' ---
+string(2) "06"
+--- testing: '65' ^ '65' ---
+string(4) "0000"
+--- testing: '65' ^ '-44' ---
+string(4) "1b01"
+--- testing: '65' ^ '1.2' ---
+string(4) "071b"
+--- testing: '65' ^ '-7.7' ---
+string(4) "1b02"
+--- testing: '65' ^ 'abc' ---
+string(4) "5757"
+--- testing: '65' ^ '123abc' ---
+string(4) "0707"
+--- testing: '65' ^ '123e5' ---
+string(4) "0707"
+--- testing: '65' ^ '123e5xyz' ---
+string(4) "0707"
+--- testing: '65' ^ ' 123abc' ---
+string(4) "1604"
+--- testing: '65' ^ '123 abc' ---
+string(4) "0707"
+--- testing: '65' ^ '123abc ' ---
+string(4) "0707"
+--- testing: '65' ^ '3.4a' ---
+string(4) "051b"
+--- testing: '65' ^ 'a5.9' ---
+string(4) "5700"
+--- testing: '-44' ^ '0' ---
+string(2) "1d"
+--- testing: '-44' ^ '65' ---
+string(4) "1b01"
+--- testing: '-44' ^ '-44' ---
+string(6) "000000"
+--- testing: '-44' ^ '1.2' ---
+string(6) "1c1a06"
+--- testing: '-44' ^ '-7.7' ---
+string(6) "00031a"
+--- testing: '-44' ^ 'abc' ---
+string(6) "4c5657"
+--- testing: '-44' ^ '123abc' ---
+string(6) "1c0607"
+--- testing: '-44' ^ '123e5' ---
+string(6) "1c0607"
+--- testing: '-44' ^ '123e5xyz' ---
+string(6) "1c0607"
+--- testing: '-44' ^ ' 123abc' ---
+string(6) "0d0506"
+--- testing: '-44' ^ '123 abc' ---
+string(6) "1c0607"
+--- testing: '-44' ^ '123abc ' ---
+string(6) "1c0607"
+--- testing: '-44' ^ '3.4a' ---
+string(6) "1e1a00"
+--- testing: '-44' ^ 'a5.9' ---
+string(6) "4c011a"
+--- testing: '1.2' ^ '0' ---
+string(2) "01"
+--- testing: '1.2' ^ '65' ---
+string(4) "071b"
+--- testing: '1.2' ^ '-44' ---
+string(6) "1c1a06"
+--- testing: '1.2' ^ '1.2' ---
+string(6) "000000"
+--- testing: '1.2' ^ '-7.7' ---
+string(6) "1c191c"
+--- testing: '1.2' ^ 'abc' ---
+string(6) "504c51"
+--- testing: '1.2' ^ '123abc' ---
+string(6) "001c01"
+--- testing: '1.2' ^ '123e5' ---
+string(6) "001c01"
+--- testing: '1.2' ^ '123e5xyz' ---
+string(6) "001c01"
+--- testing: '1.2' ^ ' 123abc' ---
+string(6) "111f00"
+--- testing: '1.2' ^ '123 abc' ---
+string(6) "001c01"
+--- testing: '1.2' ^ '123abc ' ---
+string(6) "001c01"
+--- testing: '1.2' ^ '3.4a' ---
+string(6) "020006"
+--- testing: '1.2' ^ 'a5.9' ---
+string(6) "501b1c"
+--- testing: '-7.7' ^ '0' ---
+string(2) "1d"
+--- testing: '-7.7' ^ '65' ---
+string(4) "1b02"
+--- testing: '-7.7' ^ '-44' ---
+string(6) "00031a"
+--- testing: '-7.7' ^ '1.2' ---
+string(6) "1c191c"
+--- testing: '-7.7' ^ '-7.7' ---
+string(8) "00000000"
+--- testing: '-7.7' ^ 'abc' ---
+string(6) "4c554d"
+--- testing: '-7.7' ^ '123abc' ---
+string(8) "1c051d56"
+--- testing: '-7.7' ^ '123e5' ---
+string(8) "1c051d52"
+--- testing: '-7.7' ^ '123e5xyz' ---
+string(8) "1c051d52"
+--- testing: '-7.7' ^ ' 123abc' ---
+string(8) "0d061c04"
+--- testing: '-7.7' ^ '123 abc' ---
+string(8) "1c051d17"
+--- testing: '-7.7' ^ '123abc ' ---
+string(8) "1c051d56"
+--- testing: '-7.7' ^ '3.4a' ---
+string(8) "1e191a56"
+--- testing: '-7.7' ^ 'a5.9' ---
+string(8) "4c02000e"
+--- testing: 'abc' ^ '0' ---
+string(2) "51"
+--- testing: 'abc' ^ '65' ---
+string(4) "5757"
+--- testing: 'abc' ^ '-44' ---
+string(6) "4c5657"
+--- testing: 'abc' ^ '1.2' ---
+string(6) "504c51"
+--- testing: 'abc' ^ '-7.7' ---
+string(6) "4c554d"
+--- testing: 'abc' ^ 'abc' ---
+string(6) "000000"
+--- testing: 'abc' ^ '123abc' ---
+string(6) "505050"
+--- testing: 'abc' ^ '123e5' ---
+string(6) "505050"
+--- testing: 'abc' ^ '123e5xyz' ---
+string(6) "505050"
+--- testing: 'abc' ^ ' 123abc' ---
+string(6) "415351"
+--- testing: 'abc' ^ '123 abc' ---
+string(6) "505050"
+--- testing: 'abc' ^ '123abc ' ---
+string(6) "505050"
+--- testing: 'abc' ^ '3.4a' ---
+string(6) "524c57"
+--- testing: 'abc' ^ 'a5.9' ---
+string(6) "00574d"
+--- testing: '123abc' ^ '0' ---
+string(2) "01"
+--- testing: '123abc' ^ '65' ---
+string(4) "0707"
+--- testing: '123abc' ^ '-44' ---
+string(6) "1c0607"
+--- testing: '123abc' ^ '1.2' ---
+string(6) "001c01"
+--- testing: '123abc' ^ '-7.7' ---
+string(8) "1c051d56"
+--- testing: '123abc' ^ 'abc' ---
+string(6) "505050"
+--- testing: '123abc' ^ '123abc' ---
+string(12) "000000000000"
+--- testing: '123abc' ^ '123e5' ---
+string(10) "0000000457"
+--- testing: '123abc' ^ '123e5xyz' ---
+string(12) "00000004571b"
+--- testing: '123abc' ^ ' 123abc' ---
+string(12) "110301520301"
+--- testing: '123abc' ^ '123 abc' ---
+string(12) "000000410301"
+--- testing: '123abc' ^ '123abc ' ---
+string(12) "000000000000"
+--- testing: '123abc' ^ '3.4a' ---
+string(8) "021c0700"
+--- testing: '123abc' ^ 'a5.9' ---
+string(8) "50071d58"
+--- testing: '123e5' ^ '0' ---
+string(2) "01"
+--- testing: '123e5' ^ '65' ---
+string(4) "0707"
+--- testing: '123e5' ^ '-44' ---
+string(6) "1c0607"
+--- testing: '123e5' ^ '1.2' ---
+string(6) "001c01"
+--- testing: '123e5' ^ '-7.7' ---
+string(8) "1c051d52"
+--- testing: '123e5' ^ 'abc' ---
+string(6) "505050"
+--- testing: '123e5' ^ '123abc' ---
+string(10) "0000000457"
+--- testing: '123e5' ^ '123e5' ---
+string(10) "0000000000"
+--- testing: '123e5' ^ '123e5xyz' ---
+string(10) "0000000000"
+--- testing: '123e5' ^ ' 123abc' ---
+string(10) "1103015654"
+--- testing: '123e5' ^ '123 abc' ---
+string(10) "0000004554"
+--- testing: '123e5' ^ '123abc ' ---
+string(10) "0000000457"
+--- testing: '123e5' ^ '3.4a' ---
+string(8) "021c0704"
+--- testing: '123e5' ^ 'a5.9' ---
+string(8) "50071d5c"
+--- testing: '123e5xyz' ^ '0' ---
+string(2) "01"
+--- testing: '123e5xyz' ^ '65' ---
+string(4) "0707"
+--- testing: '123e5xyz' ^ '-44' ---
+string(6) "1c0607"
+--- testing: '123e5xyz' ^ '1.2' ---
+string(6) "001c01"
+--- testing: '123e5xyz' ^ '-7.7' ---
+string(8) "1c051d52"
+--- testing: '123e5xyz' ^ 'abc' ---
+string(6) "505050"
+--- testing: '123e5xyz' ^ '123abc' ---
+string(12) "00000004571b"
+--- testing: '123e5xyz' ^ '123e5' ---
+string(10) "0000000000"
+--- testing: '123e5xyz' ^ '123e5xyz' ---
+string(16) "0000000000000000"
+--- testing: '123e5xyz' ^ ' 123abc' ---
+string(14) "11030156541a1a"
+--- testing: '123e5xyz' ^ '123 abc' ---
+string(14) "00000045541a1a"
+--- testing: '123e5xyz' ^ '123abc ' ---
+string(14) "00000004571b59"
+--- testing: '123e5xyz' ^ '3.4a' ---
+string(8) "021c0704"
+--- testing: '123e5xyz' ^ 'a5.9' ---
+string(8) "50071d5c"
+--- testing: ' 123abc' ^ '0' ---
+string(2) "10"
+--- testing: ' 123abc' ^ '65' ---
+string(4) "1604"
+--- testing: ' 123abc' ^ '-44' ---
+string(6) "0d0506"
+--- testing: ' 123abc' ^ '1.2' ---
+string(6) "111f00"
+--- testing: ' 123abc' ^ '-7.7' ---
+string(8) "0d061c04"
+--- testing: ' 123abc' ^ 'abc' ---
+string(6) "415351"
+--- testing: ' 123abc' ^ '123abc' ---
+string(12) "110301520301"
+--- testing: ' 123abc' ^ '123e5' ---
+string(10) "1103015654"
+--- testing: ' 123abc' ^ '123e5xyz' ---
+string(14) "11030156541a1a"
+--- testing: ' 123abc' ^ ' 123abc' ---
+string(14) "00000000000000"
+--- testing: ' 123abc' ^ '123 abc' ---
+string(14) "11030113000000"
+--- testing: ' 123abc' ^ '123abc ' ---
+string(14) "11030152030143"
+--- testing: ' 123abc' ^ '3.4a' ---
+string(8) "131f0652"
+--- testing: ' 123abc' ^ 'a5.9' ---
+string(8) "41041c0a"
+--- testing: '123 abc' ^ '0' ---
+string(2) "01"
+--- testing: '123 abc' ^ '65' ---
+string(4) "0707"
+--- testing: '123 abc' ^ '-44' ---
+string(6) "1c0607"
+--- testing: '123 abc' ^ '1.2' ---
+string(6) "001c01"
+--- testing: '123 abc' ^ '-7.7' ---
+string(8) "1c051d17"
+--- testing: '123 abc' ^ 'abc' ---
+string(6) "505050"
+--- testing: '123 abc' ^ '123abc' ---
+string(12) "000000410301"
+--- testing: '123 abc' ^ '123e5' ---
+string(10) "0000004554"
+--- testing: '123 abc' ^ '123e5xyz' ---
+string(14) "00000045541a1a"
+--- testing: '123 abc' ^ ' 123abc' ---
+string(14) "11030113000000"
+--- testing: '123 abc' ^ '123 abc' ---
+string(14) "00000000000000"
+--- testing: '123 abc' ^ '123abc ' ---
+string(14) "00000041030143"
+--- testing: '123 abc' ^ '3.4a' ---
+string(8) "021c0741"
+--- testing: '123 abc' ^ 'a5.9' ---
+string(8) "50071d19"
+--- testing: '123abc ' ^ '0' ---
+string(2) "01"
+--- testing: '123abc ' ^ '65' ---
+string(4) "0707"
+--- testing: '123abc ' ^ '-44' ---
+string(6) "1c0607"
+--- testing: '123abc ' ^ '1.2' ---
+string(6) "001c01"
+--- testing: '123abc ' ^ '-7.7' ---
+string(8) "1c051d56"
+--- testing: '123abc ' ^ 'abc' ---
+string(6) "505050"
+--- testing: '123abc ' ^ '123abc' ---
+string(12) "000000000000"
+--- testing: '123abc ' ^ '123e5' ---
+string(10) "0000000457"
+--- testing: '123abc ' ^ '123e5xyz' ---
+string(14) "00000004571b59"
+--- testing: '123abc ' ^ ' 123abc' ---
+string(14) "11030152030143"
+--- testing: '123abc ' ^ '123 abc' ---
+string(14) "00000041030143"
+--- testing: '123abc ' ^ '123abc ' ---
+string(14) "00000000000000"
+--- testing: '123abc ' ^ '3.4a' ---
+string(8) "021c0700"
+--- testing: '123abc ' ^ 'a5.9' ---
+string(8) "50071d58"
+--- testing: '3.4a' ^ '0' ---
+string(2) "03"
+--- testing: '3.4a' ^ '65' ---
+string(4) "051b"
+--- testing: '3.4a' ^ '-44' ---
+string(6) "1e1a00"
+--- testing: '3.4a' ^ '1.2' ---
+string(6) "020006"
+--- testing: '3.4a' ^ '-7.7' ---
+string(8) "1e191a56"
+--- testing: '3.4a' ^ 'abc' ---
+string(6) "524c57"
+--- testing: '3.4a' ^ '123abc' ---
+string(8) "021c0700"
+--- testing: '3.4a' ^ '123e5' ---
+string(8) "021c0704"
+--- testing: '3.4a' ^ '123e5xyz' ---
+string(8) "021c0704"
+--- testing: '3.4a' ^ ' 123abc' ---
+string(8) "131f0652"
+--- testing: '3.4a' ^ '123 abc' ---
+string(8) "021c0741"
+--- testing: '3.4a' ^ '123abc ' ---
+string(8) "021c0700"
+--- testing: '3.4a' ^ '3.4a' ---
+string(8) "00000000"
+--- testing: '3.4a' ^ 'a5.9' ---
+string(8) "521b1a58"
+--- testing: 'a5.9' ^ '0' ---
+string(2) "51"
+--- testing: 'a5.9' ^ '65' ---
+string(4) "5700"
+--- testing: 'a5.9' ^ '-44' ---
+string(6) "4c011a"
+--- testing: 'a5.9' ^ '1.2' ---
+string(6) "501b1c"
+--- testing: 'a5.9' ^ '-7.7' ---
+string(8) "4c02000e"
+--- testing: 'a5.9' ^ 'abc' ---
+string(6) "00574d"
+--- testing: 'a5.9' ^ '123abc' ---
+string(8) "50071d58"
+--- testing: 'a5.9' ^ '123e5' ---
+string(8) "50071d5c"
+--- testing: 'a5.9' ^ '123e5xyz' ---
+string(8) "50071d5c"
+--- testing: 'a5.9' ^ ' 123abc' ---
+string(8) "41041c0a"
+--- testing: 'a5.9' ^ '123 abc' ---
+string(8) "50071d19"
+--- testing: 'a5.9' ^ '123abc ' ---
+string(8) "50071d58"
+--- testing: 'a5.9' ^ '3.4a' ---
+string(8) "521b1a58"
+--- testing: 'a5.9' ^ 'a5.9' ---
+string(8) "00000000"
+===DONE===
diff --git a/tests/lang/operators/divide_basiclong_64bit.phpt b/tests/lang/operators/divide_basiclong_64bit.phpt
new file mode 100644
index 0000000000..b5d6df9bba
--- /dev/null
+++ b/tests/lang/operators/divide_basiclong_64bit.phpt
@@ -0,0 +1,582 @@
+--TEST--
+Test / operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
+
+error_reporting(E_ERROR);
+
+foreach ($longVals as $longVal) {
+ foreach($otherVals as $otherVal) {
+ echo "--- testing: $longVal / $otherVal ---\n";
+ var_dump($longVal/$otherVal);
+ }
+}
+
+foreach ($otherVals as $otherVal) {
+ foreach($longVals as $longVal) {
+ echo "--- testing: $otherVal / $longVal ---\n";
+ var_dump($otherVal/$longVal);
+ }
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 / 0 ---
+bool(false)
+--- testing: 9223372036854775807 / 1 ---
+int(9223372036854775807)
+--- testing: 9223372036854775807 / -1 ---
+int(-9223372036854775807)
+--- testing: 9223372036854775807 / 7 ---
+int(1317624576693539401)
+--- testing: 9223372036854775807 / 9 ---
+float(1.0248191152061E+18)
+--- testing: 9223372036854775807 / 65 ---
+float(1.4189803133623E+17)
+--- testing: 9223372036854775807 / -44 ---
+float(-2.096220917467E+17)
+--- testing: 9223372036854775807 / 2147483647 ---
+float(4294967298)
+--- testing: 9223372036854775807 / 9223372036854775807 ---
+int(1)
+--- testing: -9223372036854775808 / 0 ---
+bool(false)
+--- testing: -9223372036854775808 / 1 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775808 / -1 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775808 / 7 ---
+float(-1.3176245766935E+18)
+--- testing: -9223372036854775808 / 9 ---
+float(-1.0248191152061E+18)
+--- testing: -9223372036854775808 / 65 ---
+float(-1.4189803133623E+17)
+--- testing: -9223372036854775808 / -44 ---
+float(2.096220917467E+17)
+--- testing: -9223372036854775808 / 2147483647 ---
+float(-4294967298)
+--- testing: -9223372036854775808 / 9223372036854775807 ---
+float(-1)
+--- testing: 2147483647 / 0 ---
+bool(false)
+--- testing: 2147483647 / 1 ---
+int(2147483647)
+--- testing: 2147483647 / -1 ---
+int(-2147483647)
+--- testing: 2147483647 / 7 ---
+float(306783378.14286)
+--- testing: 2147483647 / 9 ---
+float(238609294.11111)
+--- testing: 2147483647 / 65 ---
+float(33038209.953846)
+--- testing: 2147483647 / -44 ---
+float(-48806446.522727)
+--- testing: 2147483647 / 2147483647 ---
+int(1)
+--- testing: 2147483647 / 9223372036854775807 ---
+float(2.3283064354545E-10)
+--- testing: -2147483648 / 0 ---
+bool(false)
+--- testing: -2147483648 / 1 ---
+int(-2147483648)
+--- testing: -2147483648 / -1 ---
+int(2147483648)
+--- testing: -2147483648 / 7 ---
+float(-306783378.28571)
+--- testing: -2147483648 / 9 ---
+float(-238609294.22222)
+--- testing: -2147483648 / 65 ---
+float(-33038209.969231)
+--- testing: -2147483648 / -44 ---
+float(48806446.545455)
+--- testing: -2147483648 / 2147483647 ---
+float(-1.0000000004657)
+--- testing: -2147483648 / 9223372036854775807 ---
+float(-2.3283064365387E-10)
+--- testing: 9223372034707292160 / 0 ---
+bool(false)
+--- testing: 9223372034707292160 / 1 ---
+int(9223372034707292160)
+--- testing: 9223372034707292160 / -1 ---
+int(-9223372034707292160)
+--- testing: 9223372034707292160 / 7 ---
+float(1.3176245763868E+18)
+--- testing: 9223372034707292160 / 9 ---
+float(1.0248191149675E+18)
+--- testing: 9223372034707292160 / 65 ---
+float(1.4189803130319E+17)
+--- testing: 9223372034707292160 / -44 ---
+float(-2.0962209169789E+17)
+--- testing: 9223372034707292160 / 2147483647 ---
+float(4294967297)
+--- testing: 9223372034707292160 / 9223372036854775807 ---
+float(0.99999999976717)
+--- testing: -9223372034707292160 / 0 ---
+bool(false)
+--- testing: -9223372034707292160 / 1 ---
+int(-9223372034707292160)
+--- testing: -9223372034707292160 / -1 ---
+int(9223372034707292160)
+--- testing: -9223372034707292160 / 7 ---
+float(-1.3176245763868E+18)
+--- testing: -9223372034707292160 / 9 ---
+float(-1.0248191149675E+18)
+--- testing: -9223372034707292160 / 65 ---
+float(-1.4189803130319E+17)
+--- testing: -9223372034707292160 / -44 ---
+float(2.0962209169789E+17)
+--- testing: -9223372034707292160 / 2147483647 ---
+float(-4294967297)
+--- testing: -9223372034707292160 / 9223372036854775807 ---
+float(-0.99999999976717)
+--- testing: 2147483648 / 0 ---
+bool(false)
+--- testing: 2147483648 / 1 ---
+int(2147483648)
+--- testing: 2147483648 / -1 ---
+int(-2147483648)
+--- testing: 2147483648 / 7 ---
+float(306783378.28571)
+--- testing: 2147483648 / 9 ---
+float(238609294.22222)
+--- testing: 2147483648 / 65 ---
+float(33038209.969231)
+--- testing: 2147483648 / -44 ---
+float(-48806446.545455)
+--- testing: 2147483648 / 2147483647 ---
+float(1.0000000004657)
+--- testing: 2147483648 / 9223372036854775807 ---
+float(2.3283064365387E-10)
+--- testing: -2147483649 / 0 ---
+bool(false)
+--- testing: -2147483649 / 1 ---
+int(-2147483649)
+--- testing: -2147483649 / -1 ---
+int(2147483649)
+--- testing: -2147483649 / 7 ---
+float(-306783378.42857)
+--- testing: -2147483649 / 9 ---
+float(-238609294.33333)
+--- testing: -2147483649 / 65 ---
+float(-33038209.984615)
+--- testing: -2147483649 / -44 ---
+float(48806446.568182)
+--- testing: -2147483649 / 2147483647 ---
+float(-1.0000000009313)
+--- testing: -2147483649 / 9223372036854775807 ---
+float(-2.3283064376229E-10)
+--- testing: 4294967294 / 0 ---
+bool(false)
+--- testing: 4294967294 / 1 ---
+int(4294967294)
+--- testing: 4294967294 / -1 ---
+int(-4294967294)
+--- testing: 4294967294 / 7 ---
+float(613566756.28571)
+--- testing: 4294967294 / 9 ---
+float(477218588.22222)
+--- testing: 4294967294 / 65 ---
+float(66076419.907692)
+--- testing: 4294967294 / -44 ---
+float(-97612893.045455)
+--- testing: 4294967294 / 2147483647 ---
+int(2)
+--- testing: 4294967294 / 9223372036854775807 ---
+float(4.656612870909E-10)
+--- testing: 4294967295 / 0 ---
+bool(false)
+--- testing: 4294967295 / 1 ---
+int(4294967295)
+--- testing: 4294967295 / -1 ---
+int(-4294967295)
+--- testing: 4294967295 / 7 ---
+float(613566756.42857)
+--- testing: 4294967295 / 9 ---
+float(477218588.33333)
+--- testing: 4294967295 / 65 ---
+float(66076419.923077)
+--- testing: 4294967295 / -44 ---
+float(-97612893.068182)
+--- testing: 4294967295 / 2147483647 ---
+float(2.0000000004657)
+--- testing: 4294967295 / 9223372036854775807 ---
+float(4.6566128719932E-10)
+--- testing: 4294967293 / 0 ---
+bool(false)
+--- testing: 4294967293 / 1 ---
+int(4294967293)
+--- testing: 4294967293 / -1 ---
+int(-4294967293)
+--- testing: 4294967293 / 7 ---
+float(613566756.14286)
+--- testing: 4294967293 / 9 ---
+float(477218588.11111)
+--- testing: 4294967293 / 65 ---
+float(66076419.892308)
+--- testing: 4294967293 / -44 ---
+float(-97612893.022727)
+--- testing: 4294967293 / 2147483647 ---
+float(1.9999999995343)
+--- testing: 4294967293 / 9223372036854775807 ---
+float(4.6566128698248E-10)
+--- testing: 9223372036854775806 / 0 ---
+bool(false)
+--- testing: 9223372036854775806 / 1 ---
+int(9223372036854775806)
+--- testing: 9223372036854775806 / -1 ---
+int(-9223372036854775806)
+--- testing: 9223372036854775806 / 7 ---
+float(1.3176245766935E+18)
+--- testing: 9223372036854775806 / 9 ---
+float(1.0248191152061E+18)
+--- testing: 9223372036854775806 / 65 ---
+float(1.4189803133623E+17)
+--- testing: 9223372036854775806 / -44 ---
+float(-2.096220917467E+17)
+--- testing: 9223372036854775806 / 2147483647 ---
+int(4294967298)
+--- testing: 9223372036854775806 / 9223372036854775807 ---
+float(1)
+--- testing: 9.2233720368548E+18 / 0 ---
+bool(false)
+--- testing: 9.2233720368548E+18 / 1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 / -1 ---
+float(-9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 / 7 ---
+float(1.3176245766935E+18)
+--- testing: 9.2233720368548E+18 / 9 ---
+float(1.0248191152061E+18)
+--- testing: 9.2233720368548E+18 / 65 ---
+float(1.4189803133623E+17)
+--- testing: 9.2233720368548E+18 / -44 ---
+float(-2.096220917467E+17)
+--- testing: 9.2233720368548E+18 / 2147483647 ---
+float(4294967298)
+--- testing: 9.2233720368548E+18 / 9223372036854775807 ---
+float(1)
+--- testing: -9223372036854775807 / 0 ---
+bool(false)
+--- testing: -9223372036854775807 / 1 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775807 / -1 ---
+int(9223372036854775807)
+--- testing: -9223372036854775807 / 7 ---
+int(-1317624576693539401)
+--- testing: -9223372036854775807 / 9 ---
+float(-1.0248191152061E+18)
+--- testing: -9223372036854775807 / 65 ---
+float(-1.4189803133623E+17)
+--- testing: -9223372036854775807 / -44 ---
+float(2.096220917467E+17)
+--- testing: -9223372036854775807 / 2147483647 ---
+float(-4294967298)
+--- testing: -9223372036854775807 / 9223372036854775807 ---
+int(-1)
+--- testing: -9.2233720368548E+18 / 0 ---
+bool(false)
+--- testing: -9.2233720368548E+18 / 1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 / -1 ---
+float(9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 / 7 ---
+float(-1.3176245766935E+18)
+--- testing: -9.2233720368548E+18 / 9 ---
+float(-1.0248191152061E+18)
+--- testing: -9.2233720368548E+18 / 65 ---
+float(-1.4189803133623E+17)
+--- testing: -9.2233720368548E+18 / -44 ---
+float(2.096220917467E+17)
+--- testing: -9.2233720368548E+18 / 2147483647 ---
+float(-4294967298)
+--- testing: -9.2233720368548E+18 / 9223372036854775807 ---
+float(-1)
+--- testing: 0 / 9223372036854775807 ---
+int(0)
+--- testing: 0 / -9223372036854775808 ---
+int(0)
+--- testing: 0 / 2147483647 ---
+int(0)
+--- testing: 0 / -2147483648 ---
+int(0)
+--- testing: 0 / 9223372034707292160 ---
+int(0)
+--- testing: 0 / -9223372034707292160 ---
+int(0)
+--- testing: 0 / 2147483648 ---
+int(0)
+--- testing: 0 / -2147483649 ---
+int(0)
+--- testing: 0 / 4294967294 ---
+int(0)
+--- testing: 0 / 4294967295 ---
+int(0)
+--- testing: 0 / 4294967293 ---
+int(0)
+--- testing: 0 / 9223372036854775806 ---
+int(0)
+--- testing: 0 / 9.2233720368548E+18 ---
+float(0)
+--- testing: 0 / -9223372036854775807 ---
+int(0)
+--- testing: 0 / -9.2233720368548E+18 ---
+float(-0)
+--- testing: 1 / 9223372036854775807 ---
+float(1.0842021724855E-19)
+--- testing: 1 / -9223372036854775808 ---
+float(-1.0842021724855E-19)
+--- testing: 1 / 2147483647 ---
+float(4.6566128752458E-10)
+--- testing: 1 / -2147483648 ---
+float(-4.6566128730774E-10)
+--- testing: 1 / 9223372034707292160 ---
+float(1.0842021727379E-19)
+--- testing: 1 / -9223372034707292160 ---
+float(-1.0842021727379E-19)
+--- testing: 1 / 2147483648 ---
+float(4.6566128730774E-10)
+--- testing: 1 / -2147483649 ---
+float(-4.656612870909E-10)
+--- testing: 1 / 4294967294 ---
+float(2.3283064376229E-10)
+--- testing: 1 / 4294967295 ---
+float(2.3283064370808E-10)
+--- testing: 1 / 4294967293 ---
+float(2.328306438165E-10)
+--- testing: 1 / 9223372036854775806 ---
+float(1.0842021724855E-19)
+--- testing: 1 / 9.2233720368548E+18 ---
+float(1.0842021724855E-19)
+--- testing: 1 / -9223372036854775807 ---
+float(-1.0842021724855E-19)
+--- testing: 1 / -9.2233720368548E+18 ---
+float(-1.0842021724855E-19)
+--- testing: -1 / 9223372036854775807 ---
+float(-1.0842021724855E-19)
+--- testing: -1 / -9223372036854775808 ---
+float(1.0842021724855E-19)
+--- testing: -1 / 2147483647 ---
+float(-4.6566128752458E-10)
+--- testing: -1 / -2147483648 ---
+float(4.6566128730774E-10)
+--- testing: -1 / 9223372034707292160 ---
+float(-1.0842021727379E-19)
+--- testing: -1 / -9223372034707292160 ---
+float(1.0842021727379E-19)
+--- testing: -1 / 2147483648 ---
+float(-4.6566128730774E-10)
+--- testing: -1 / -2147483649 ---
+float(4.656612870909E-10)
+--- testing: -1 / 4294967294 ---
+float(-2.3283064376229E-10)
+--- testing: -1 / 4294967295 ---
+float(-2.3283064370808E-10)
+--- testing: -1 / 4294967293 ---
+float(-2.328306438165E-10)
+--- testing: -1 / 9223372036854775806 ---
+float(-1.0842021724855E-19)
+--- testing: -1 / 9.2233720368548E+18 ---
+float(-1.0842021724855E-19)
+--- testing: -1 / -9223372036854775807 ---
+float(1.0842021724855E-19)
+--- testing: -1 / -9.2233720368548E+18 ---
+float(1.0842021724855E-19)
+--- testing: 7 / 9223372036854775807 ---
+float(7.5894152073985E-19)
+--- testing: 7 / -9223372036854775808 ---
+float(-7.5894152073985E-19)
+--- testing: 7 / 2147483647 ---
+float(3.2596290126721E-9)
+--- testing: 7 / -2147483648 ---
+float(-3.2596290111542E-9)
+--- testing: 7 / 9223372034707292160 ---
+float(7.5894152091656E-19)
+--- testing: 7 / -9223372034707292160 ---
+float(-7.5894152091656E-19)
+--- testing: 7 / 2147483648 ---
+float(3.2596290111542E-9)
+--- testing: 7 / -2147483649 ---
+float(-3.2596290096363E-9)
+--- testing: 7 / 4294967294 ---
+float(1.629814506336E-9)
+--- testing: 7 / 4294967295 ---
+float(1.6298145059566E-9)
+--- testing: 7 / 4294967293 ---
+float(1.6298145067155E-9)
+--- testing: 7 / 9223372036854775806 ---
+float(7.5894152073985E-19)
+--- testing: 7 / 9.2233720368548E+18 ---
+float(7.5894152073985E-19)
+--- testing: 7 / -9223372036854775807 ---
+float(-7.5894152073985E-19)
+--- testing: 7 / -9.2233720368548E+18 ---
+float(-7.5894152073985E-19)
+--- testing: 9 / 9223372036854775807 ---
+float(9.7578195523695E-19)
+--- testing: 9 / -9223372036854775808 ---
+float(-9.7578195523695E-19)
+--- testing: 9 / 2147483647 ---
+float(4.1909515877212E-9)
+--- testing: 9 / -2147483648 ---
+float(-4.1909515857697E-9)
+--- testing: 9 / 9223372034707292160 ---
+float(9.7578195546415E-19)
+--- testing: 9 / -9223372034707292160 ---
+float(-9.7578195546415E-19)
+--- testing: 9 / 2147483648 ---
+float(4.1909515857697E-9)
+--- testing: 9 / -2147483649 ---
+float(-4.1909515838181E-9)
+--- testing: 9 / 4294967294 ---
+float(2.0954757938606E-9)
+--- testing: 9 / 4294967295 ---
+float(2.0954757933727E-9)
+--- testing: 9 / 4294967293 ---
+float(2.0954757943485E-9)
+--- testing: 9 / 9223372036854775806 ---
+float(9.7578195523695E-19)
+--- testing: 9 / 9.2233720368548E+18 ---
+float(9.7578195523695E-19)
+--- testing: 9 / -9223372036854775807 ---
+float(-9.7578195523695E-19)
+--- testing: 9 / -9.2233720368548E+18 ---
+float(-9.7578195523695E-19)
+--- testing: 65 / 9223372036854775807 ---
+float(7.0473141211558E-18)
+--- testing: 65 / -9223372036854775808 ---
+float(-7.0473141211558E-18)
+--- testing: 65 / 2147483647 ---
+float(3.0267983689098E-8)
+--- testing: 65 / -2147483648 ---
+float(-3.0267983675003E-8)
+--- testing: 65 / 9223372034707292160 ---
+float(7.0473141227966E-18)
+--- testing: 65 / -9223372034707292160 ---
+float(-7.0473141227966E-18)
+--- testing: 65 / 2147483648 ---
+float(3.0267983675003E-8)
+--- testing: 65 / -2147483649 ---
+float(-3.0267983660908E-8)
+--- testing: 65 / 4294967294 ---
+float(1.5133991844549E-8)
+--- testing: 65 / 4294967295 ---
+float(1.5133991841025E-8)
+--- testing: 65 / 4294967293 ---
+float(1.5133991848072E-8)
+--- testing: 65 / 9223372036854775806 ---
+float(7.0473141211558E-18)
+--- testing: 65 / 9.2233720368548E+18 ---
+float(7.0473141211558E-18)
+--- testing: 65 / -9223372036854775807 ---
+float(-7.0473141211558E-18)
+--- testing: 65 / -9.2233720368548E+18 ---
+float(-7.0473141211558E-18)
+--- testing: -44 / 9223372036854775807 ---
+float(-4.7704895589362E-18)
+--- testing: -44 / -9223372036854775808 ---
+float(4.7704895589362E-18)
+--- testing: -44 / 2147483647 ---
+float(-2.0489096651082E-8)
+--- testing: -44 / -2147483648 ---
+float(2.0489096641541E-8)
+--- testing: -44 / 9223372034707292160 ---
+float(-4.7704895600469E-18)
+--- testing: -44 / -9223372034707292160 ---
+float(4.7704895600469E-18)
+--- testing: -44 / 2147483648 ---
+float(-2.0489096641541E-8)
+--- testing: -44 / -2147483649 ---
+float(2.0489096632E-8)
+--- testing: -44 / 4294967294 ---
+float(-1.0244548325541E-8)
+--- testing: -44 / 4294967295 ---
+float(-1.0244548323156E-8)
+--- testing: -44 / 4294967293 ---
+float(-1.0244548327926E-8)
+--- testing: -44 / 9223372036854775806 ---
+float(-4.7704895589362E-18)
+--- testing: -44 / 9.2233720368548E+18 ---
+float(-4.7704895589362E-18)
+--- testing: -44 / -9223372036854775807 ---
+float(4.7704895589362E-18)
+--- testing: -44 / -9.2233720368548E+18 ---
+float(4.7704895589362E-18)
+--- testing: 2147483647 / 9223372036854775807 ---
+float(2.3283064354545E-10)
+--- testing: 2147483647 / -9223372036854775808 ---
+float(-2.3283064354545E-10)
+--- testing: 2147483647 / 2147483647 ---
+int(1)
+--- testing: 2147483647 / -2147483648 ---
+float(-0.99999999953434)
+--- testing: 2147483647 / 9223372034707292160 ---
+float(2.3283064359966E-10)
+--- testing: 2147483647 / -9223372034707292160 ---
+float(-2.3283064359966E-10)
+--- testing: 2147483647 / 2147483648 ---
+float(0.99999999953434)
+--- testing: 2147483647 / -2147483649 ---
+float(-0.99999999906868)
+--- testing: 2147483647 / 4294967294 ---
+float(0.5)
+--- testing: 2147483647 / 4294967295 ---
+float(0.49999999988358)
+--- testing: 2147483647 / 4294967293 ---
+float(0.50000000011642)
+--- testing: 2147483647 / 9223372036854775806 ---
+float(2.3283064354545E-10)
+--- testing: 2147483647 / 9.2233720368548E+18 ---
+float(2.3283064354545E-10)
+--- testing: 2147483647 / -9223372036854775807 ---
+float(-2.3283064354545E-10)
+--- testing: 2147483647 / -9.2233720368548E+18 ---
+float(-2.3283064354545E-10)
+--- testing: 9223372036854775807 / 9223372036854775807 ---
+int(1)
+--- testing: 9223372036854775807 / -9223372036854775808 ---
+float(-1)
+--- testing: 9223372036854775807 / 2147483647 ---
+float(4294967298)
+--- testing: 9223372036854775807 / -2147483648 ---
+float(-4294967296)
+--- testing: 9223372036854775807 / 9223372034707292160 ---
+float(1.0000000002328)
+--- testing: 9223372036854775807 / -9223372034707292160 ---
+float(-1.0000000002328)
+--- testing: 9223372036854775807 / 2147483648 ---
+float(4294967296)
+--- testing: 9223372036854775807 / -2147483649 ---
+float(-4294967294)
+--- testing: 9223372036854775807 / 4294967294 ---
+float(2147483649)
+--- testing: 9223372036854775807 / 4294967295 ---
+float(2147483648.5)
+--- testing: 9223372036854775807 / 4294967293 ---
+float(2147483649.5)
+--- testing: 9223372036854775807 / 9223372036854775806 ---
+float(1)
+--- testing: 9223372036854775807 / 9.2233720368548E+18 ---
+float(1)
+--- testing: 9223372036854775807 / -9223372036854775807 ---
+int(-1)
+--- testing: 9223372036854775807 / -9.2233720368548E+18 ---
+float(-1)
+===DONE===
diff --git a/tests/lang/operators/divide_variationStr.phpt b/tests/lang/operators/divide_variationStr.phpt
new file mode 100644
index 0000000000..e48e9e1750
--- /dev/null
+++ b/tests/lang/operators/divide_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test / operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' / '$otherVal' ---\n";
+ var_dump($strVal/$otherVal);
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' / '0' ---
+bool(false)
+--- testing: '0' / '65' ---
+int(0)
+--- testing: '0' / '-44' ---
+int(0)
+--- testing: '0' / '1.2' ---
+float(0)
+--- testing: '0' / '-7.7' ---
+float(-0)
+--- testing: '0' / 'abc' ---
+bool(false)
+--- testing: '0' / '123abc' ---
+int(0)
+--- testing: '0' / '123e5' ---
+float(0)
+--- testing: '0' / '123e5xyz' ---
+float(0)
+--- testing: '0' / ' 123abc' ---
+int(0)
+--- testing: '0' / '123 abc' ---
+int(0)
+--- testing: '0' / '123abc ' ---
+int(0)
+--- testing: '0' / '3.4a' ---
+float(0)
+--- testing: '0' / 'a5.9' ---
+bool(false)
+--- testing: '65' / '0' ---
+bool(false)
+--- testing: '65' / '65' ---
+int(1)
+--- testing: '65' / '-44' ---
+float(-1.4772727272727)
+--- testing: '65' / '1.2' ---
+float(54.166666666667)
+--- testing: '65' / '-7.7' ---
+float(-8.4415584415584)
+--- testing: '65' / 'abc' ---
+bool(false)
+--- testing: '65' / '123abc' ---
+float(0.52845528455285)
+--- testing: '65' / '123e5' ---
+float(5.2845528455285E-6)
+--- testing: '65' / '123e5xyz' ---
+float(5.2845528455285E-6)
+--- testing: '65' / ' 123abc' ---
+float(0.52845528455285)
+--- testing: '65' / '123 abc' ---
+float(0.52845528455285)
+--- testing: '65' / '123abc ' ---
+float(0.52845528455285)
+--- testing: '65' / '3.4a' ---
+float(19.117647058824)
+--- testing: '65' / 'a5.9' ---
+bool(false)
+--- testing: '-44' / '0' ---
+bool(false)
+--- testing: '-44' / '65' ---
+float(-0.67692307692308)
+--- testing: '-44' / '-44' ---
+int(1)
+--- testing: '-44' / '1.2' ---
+float(-36.666666666667)
+--- testing: '-44' / '-7.7' ---
+float(5.7142857142857)
+--- testing: '-44' / 'abc' ---
+bool(false)
+--- testing: '-44' / '123abc' ---
+float(-0.35772357723577)
+--- testing: '-44' / '123e5' ---
+float(-3.5772357723577E-6)
+--- testing: '-44' / '123e5xyz' ---
+float(-3.5772357723577E-6)
+--- testing: '-44' / ' 123abc' ---
+float(-0.35772357723577)
+--- testing: '-44' / '123 abc' ---
+float(-0.35772357723577)
+--- testing: '-44' / '123abc ' ---
+float(-0.35772357723577)
+--- testing: '-44' / '3.4a' ---
+float(-12.941176470588)
+--- testing: '-44' / 'a5.9' ---
+bool(false)
+--- testing: '1.2' / '0' ---
+bool(false)
+--- testing: '1.2' / '65' ---
+float(0.018461538461538)
+--- testing: '1.2' / '-44' ---
+float(-0.027272727272727)
+--- testing: '1.2' / '1.2' ---
+float(1)
+--- testing: '1.2' / '-7.7' ---
+float(-0.15584415584416)
+--- testing: '1.2' / 'abc' ---
+bool(false)
+--- testing: '1.2' / '123abc' ---
+float(0.0097560975609756)
+--- testing: '1.2' / '123e5' ---
+float(9.7560975609756E-8)
+--- testing: '1.2' / '123e5xyz' ---
+float(9.7560975609756E-8)
+--- testing: '1.2' / ' 123abc' ---
+float(0.0097560975609756)
+--- testing: '1.2' / '123 abc' ---
+float(0.0097560975609756)
+--- testing: '1.2' / '123abc ' ---
+float(0.0097560975609756)
+--- testing: '1.2' / '3.4a' ---
+float(0.35294117647059)
+--- testing: '1.2' / 'a5.9' ---
+bool(false)
+--- testing: '-7.7' / '0' ---
+bool(false)
+--- testing: '-7.7' / '65' ---
+float(-0.11846153846154)
+--- testing: '-7.7' / '-44' ---
+float(0.175)
+--- testing: '-7.7' / '1.2' ---
+float(-6.4166666666667)
+--- testing: '-7.7' / '-7.7' ---
+float(1)
+--- testing: '-7.7' / 'abc' ---
+bool(false)
+--- testing: '-7.7' / '123abc' ---
+float(-0.06260162601626)
+--- testing: '-7.7' / '123e5' ---
+float(-6.260162601626E-7)
+--- testing: '-7.7' / '123e5xyz' ---
+float(-6.260162601626E-7)
+--- testing: '-7.7' / ' 123abc' ---
+float(-0.06260162601626)
+--- testing: '-7.7' / '123 abc' ---
+float(-0.06260162601626)
+--- testing: '-7.7' / '123abc ' ---
+float(-0.06260162601626)
+--- testing: '-7.7' / '3.4a' ---
+float(-2.2647058823529)
+--- testing: '-7.7' / 'a5.9' ---
+bool(false)
+--- testing: 'abc' / '0' ---
+bool(false)
+--- testing: 'abc' / '65' ---
+int(0)
+--- testing: 'abc' / '-44' ---
+int(0)
+--- testing: 'abc' / '1.2' ---
+float(0)
+--- testing: 'abc' / '-7.7' ---
+float(-0)
+--- testing: 'abc' / 'abc' ---
+bool(false)
+--- testing: 'abc' / '123abc' ---
+int(0)
+--- testing: 'abc' / '123e5' ---
+float(0)
+--- testing: 'abc' / '123e5xyz' ---
+float(0)
+--- testing: 'abc' / ' 123abc' ---
+int(0)
+--- testing: 'abc' / '123 abc' ---
+int(0)
+--- testing: 'abc' / '123abc ' ---
+int(0)
+--- testing: 'abc' / '3.4a' ---
+float(0)
+--- testing: 'abc' / 'a5.9' ---
+bool(false)
+--- testing: '123abc' / '0' ---
+bool(false)
+--- testing: '123abc' / '65' ---
+float(1.8923076923077)
+--- testing: '123abc' / '-44' ---
+float(-2.7954545454545)
+--- testing: '123abc' / '1.2' ---
+float(102.5)
+--- testing: '123abc' / '-7.7' ---
+float(-15.974025974026)
+--- testing: '123abc' / 'abc' ---
+bool(false)
+--- testing: '123abc' / '123abc' ---
+int(1)
+--- testing: '123abc' / '123e5' ---
+float(1.0E-5)
+--- testing: '123abc' / '123e5xyz' ---
+float(1.0E-5)
+--- testing: '123abc' / ' 123abc' ---
+int(1)
+--- testing: '123abc' / '123 abc' ---
+int(1)
+--- testing: '123abc' / '123abc ' ---
+int(1)
+--- testing: '123abc' / '3.4a' ---
+float(36.176470588235)
+--- testing: '123abc' / 'a5.9' ---
+bool(false)
+--- testing: '123e5' / '0' ---
+bool(false)
+--- testing: '123e5' / '65' ---
+float(189230.76923077)
+--- testing: '123e5' / '-44' ---
+float(-279545.45454545)
+--- testing: '123e5' / '1.2' ---
+float(10250000)
+--- testing: '123e5' / '-7.7' ---
+float(-1597402.5974026)
+--- testing: '123e5' / 'abc' ---
+bool(false)
+--- testing: '123e5' / '123abc' ---
+float(100000)
+--- testing: '123e5' / '123e5' ---
+float(1)
+--- testing: '123e5' / '123e5xyz' ---
+float(1)
+--- testing: '123e5' / ' 123abc' ---
+float(100000)
+--- testing: '123e5' / '123 abc' ---
+float(100000)
+--- testing: '123e5' / '123abc ' ---
+float(100000)
+--- testing: '123e5' / '3.4a' ---
+float(3617647.0588235)
+--- testing: '123e5' / 'a5.9' ---
+bool(false)
+--- testing: '123e5xyz' / '0' ---
+bool(false)
+--- testing: '123e5xyz' / '65' ---
+float(189230.76923077)
+--- testing: '123e5xyz' / '-44' ---
+float(-279545.45454545)
+--- testing: '123e5xyz' / '1.2' ---
+float(10250000)
+--- testing: '123e5xyz' / '-7.7' ---
+float(-1597402.5974026)
+--- testing: '123e5xyz' / 'abc' ---
+bool(false)
+--- testing: '123e5xyz' / '123abc' ---
+float(100000)
+--- testing: '123e5xyz' / '123e5' ---
+float(1)
+--- testing: '123e5xyz' / '123e5xyz' ---
+float(1)
+--- testing: '123e5xyz' / ' 123abc' ---
+float(100000)
+--- testing: '123e5xyz' / '123 abc' ---
+float(100000)
+--- testing: '123e5xyz' / '123abc ' ---
+float(100000)
+--- testing: '123e5xyz' / '3.4a' ---
+float(3617647.0588235)
+--- testing: '123e5xyz' / 'a5.9' ---
+bool(false)
+--- testing: ' 123abc' / '0' ---
+bool(false)
+--- testing: ' 123abc' / '65' ---
+float(1.8923076923077)
+--- testing: ' 123abc' / '-44' ---
+float(-2.7954545454545)
+--- testing: ' 123abc' / '1.2' ---
+float(102.5)
+--- testing: ' 123abc' / '-7.7' ---
+float(-15.974025974026)
+--- testing: ' 123abc' / 'abc' ---
+bool(false)
+--- testing: ' 123abc' / '123abc' ---
+int(1)
+--- testing: ' 123abc' / '123e5' ---
+float(1.0E-5)
+--- testing: ' 123abc' / '123e5xyz' ---
+float(1.0E-5)
+--- testing: ' 123abc' / ' 123abc' ---
+int(1)
+--- testing: ' 123abc' / '123 abc' ---
+int(1)
+--- testing: ' 123abc' / '123abc ' ---
+int(1)
+--- testing: ' 123abc' / '3.4a' ---
+float(36.176470588235)
+--- testing: ' 123abc' / 'a5.9' ---
+bool(false)
+--- testing: '123 abc' / '0' ---
+bool(false)
+--- testing: '123 abc' / '65' ---
+float(1.8923076923077)
+--- testing: '123 abc' / '-44' ---
+float(-2.7954545454545)
+--- testing: '123 abc' / '1.2' ---
+float(102.5)
+--- testing: '123 abc' / '-7.7' ---
+float(-15.974025974026)
+--- testing: '123 abc' / 'abc' ---
+bool(false)
+--- testing: '123 abc' / '123abc' ---
+int(1)
+--- testing: '123 abc' / '123e5' ---
+float(1.0E-5)
+--- testing: '123 abc' / '123e5xyz' ---
+float(1.0E-5)
+--- testing: '123 abc' / ' 123abc' ---
+int(1)
+--- testing: '123 abc' / '123 abc' ---
+int(1)
+--- testing: '123 abc' / '123abc ' ---
+int(1)
+--- testing: '123 abc' / '3.4a' ---
+float(36.176470588235)
+--- testing: '123 abc' / 'a5.9' ---
+bool(false)
+--- testing: '123abc ' / '0' ---
+bool(false)
+--- testing: '123abc ' / '65' ---
+float(1.8923076923077)
+--- testing: '123abc ' / '-44' ---
+float(-2.7954545454545)
+--- testing: '123abc ' / '1.2' ---
+float(102.5)
+--- testing: '123abc ' / '-7.7' ---
+float(-15.974025974026)
+--- testing: '123abc ' / 'abc' ---
+bool(false)
+--- testing: '123abc ' / '123abc' ---
+int(1)
+--- testing: '123abc ' / '123e5' ---
+float(1.0E-5)
+--- testing: '123abc ' / '123e5xyz' ---
+float(1.0E-5)
+--- testing: '123abc ' / ' 123abc' ---
+int(1)
+--- testing: '123abc ' / '123 abc' ---
+int(1)
+--- testing: '123abc ' / '123abc ' ---
+int(1)
+--- testing: '123abc ' / '3.4a' ---
+float(36.176470588235)
+--- testing: '123abc ' / 'a5.9' ---
+bool(false)
+--- testing: '3.4a' / '0' ---
+bool(false)
+--- testing: '3.4a' / '65' ---
+float(0.052307692307692)
+--- testing: '3.4a' / '-44' ---
+float(-0.077272727272727)
+--- testing: '3.4a' / '1.2' ---
+float(2.8333333333333)
+--- testing: '3.4a' / '-7.7' ---
+float(-0.44155844155844)
+--- testing: '3.4a' / 'abc' ---
+bool(false)
+--- testing: '3.4a' / '123abc' ---
+float(0.027642276422764)
+--- testing: '3.4a' / '123e5' ---
+float(2.7642276422764E-7)
+--- testing: '3.4a' / '123e5xyz' ---
+float(2.7642276422764E-7)
+--- testing: '3.4a' / ' 123abc' ---
+float(0.027642276422764)
+--- testing: '3.4a' / '123 abc' ---
+float(0.027642276422764)
+--- testing: '3.4a' / '123abc ' ---
+float(0.027642276422764)
+--- testing: '3.4a' / '3.4a' ---
+float(1)
+--- testing: '3.4a' / 'a5.9' ---
+bool(false)
+--- testing: 'a5.9' / '0' ---
+bool(false)
+--- testing: 'a5.9' / '65' ---
+int(0)
+--- testing: 'a5.9' / '-44' ---
+int(0)
+--- testing: 'a5.9' / '1.2' ---
+float(0)
+--- testing: 'a5.9' / '-7.7' ---
+float(-0)
+--- testing: 'a5.9' / 'abc' ---
+bool(false)
+--- testing: 'a5.9' / '123abc' ---
+int(0)
+--- testing: 'a5.9' / '123e5' ---
+float(0)
+--- testing: 'a5.9' / '123e5xyz' ---
+float(0)
+--- testing: 'a5.9' / ' 123abc' ---
+int(0)
+--- testing: 'a5.9' / '123 abc' ---
+int(0)
+--- testing: 'a5.9' / '123abc ' ---
+int(0)
+--- testing: 'a5.9' / '3.4a' ---
+float(0)
+--- testing: 'a5.9' / 'a5.9' ---
+bool(false)
+===DONE===
diff --git a/tests/lang/operators/modulus_variationStr.phpt b/tests/lang/operators/modulus_variationStr.phpt
new file mode 100644
index 0000000000..7b3ce7679a
--- /dev/null
+++ b/tests/lang/operators/modulus_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test % operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' % '$otherVal' ---\n";
+ var_dump($strVal%$otherVal);
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' % '0' ---
+bool(false)
+--- testing: '0' % '65' ---
+int(0)
+--- testing: '0' % '-44' ---
+int(0)
+--- testing: '0' % '1.2' ---
+int(0)
+--- testing: '0' % '-7.7' ---
+int(0)
+--- testing: '0' % 'abc' ---
+bool(false)
+--- testing: '0' % '123abc' ---
+int(0)
+--- testing: '0' % '123e5' ---
+int(0)
+--- testing: '0' % '123e5xyz' ---
+int(0)
+--- testing: '0' % ' 123abc' ---
+int(0)
+--- testing: '0' % '123 abc' ---
+int(0)
+--- testing: '0' % '123abc ' ---
+int(0)
+--- testing: '0' % '3.4a' ---
+int(0)
+--- testing: '0' % 'a5.9' ---
+bool(false)
+--- testing: '65' % '0' ---
+bool(false)
+--- testing: '65' % '65' ---
+int(0)
+--- testing: '65' % '-44' ---
+int(21)
+--- testing: '65' % '1.2' ---
+int(0)
+--- testing: '65' % '-7.7' ---
+int(2)
+--- testing: '65' % 'abc' ---
+bool(false)
+--- testing: '65' % '123abc' ---
+int(65)
+--- testing: '65' % '123e5' ---
+int(65)
+--- testing: '65' % '123e5xyz' ---
+int(65)
+--- testing: '65' % ' 123abc' ---
+int(65)
+--- testing: '65' % '123 abc' ---
+int(65)
+--- testing: '65' % '123abc ' ---
+int(65)
+--- testing: '65' % '3.4a' ---
+int(2)
+--- testing: '65' % 'a5.9' ---
+bool(false)
+--- testing: '-44' % '0' ---
+bool(false)
+--- testing: '-44' % '65' ---
+int(-44)
+--- testing: '-44' % '-44' ---
+int(0)
+--- testing: '-44' % '1.2' ---
+int(0)
+--- testing: '-44' % '-7.7' ---
+int(-2)
+--- testing: '-44' % 'abc' ---
+bool(false)
+--- testing: '-44' % '123abc' ---
+int(-44)
+--- testing: '-44' % '123e5' ---
+int(-44)
+--- testing: '-44' % '123e5xyz' ---
+int(-44)
+--- testing: '-44' % ' 123abc' ---
+int(-44)
+--- testing: '-44' % '123 abc' ---
+int(-44)
+--- testing: '-44' % '123abc ' ---
+int(-44)
+--- testing: '-44' % '3.4a' ---
+int(-2)
+--- testing: '-44' % 'a5.9' ---
+bool(false)
+--- testing: '1.2' % '0' ---
+bool(false)
+--- testing: '1.2' % '65' ---
+int(1)
+--- testing: '1.2' % '-44' ---
+int(1)
+--- testing: '1.2' % '1.2' ---
+int(0)
+--- testing: '1.2' % '-7.7' ---
+int(1)
+--- testing: '1.2' % 'abc' ---
+bool(false)
+--- testing: '1.2' % '123abc' ---
+int(1)
+--- testing: '1.2' % '123e5' ---
+int(1)
+--- testing: '1.2' % '123e5xyz' ---
+int(1)
+--- testing: '1.2' % ' 123abc' ---
+int(1)
+--- testing: '1.2' % '123 abc' ---
+int(1)
+--- testing: '1.2' % '123abc ' ---
+int(1)
+--- testing: '1.2' % '3.4a' ---
+int(1)
+--- testing: '1.2' % 'a5.9' ---
+bool(false)
+--- testing: '-7.7' % '0' ---
+bool(false)
+--- testing: '-7.7' % '65' ---
+int(-7)
+--- testing: '-7.7' % '-44' ---
+int(-7)
+--- testing: '-7.7' % '1.2' ---
+int(0)
+--- testing: '-7.7' % '-7.7' ---
+int(0)
+--- testing: '-7.7' % 'abc' ---
+bool(false)
+--- testing: '-7.7' % '123abc' ---
+int(-7)
+--- testing: '-7.7' % '123e5' ---
+int(-7)
+--- testing: '-7.7' % '123e5xyz' ---
+int(-7)
+--- testing: '-7.7' % ' 123abc' ---
+int(-7)
+--- testing: '-7.7' % '123 abc' ---
+int(-7)
+--- testing: '-7.7' % '123abc ' ---
+int(-7)
+--- testing: '-7.7' % '3.4a' ---
+int(-1)
+--- testing: '-7.7' % 'a5.9' ---
+bool(false)
+--- testing: 'abc' % '0' ---
+bool(false)
+--- testing: 'abc' % '65' ---
+int(0)
+--- testing: 'abc' % '-44' ---
+int(0)
+--- testing: 'abc' % '1.2' ---
+int(0)
+--- testing: 'abc' % '-7.7' ---
+int(0)
+--- testing: 'abc' % 'abc' ---
+bool(false)
+--- testing: 'abc' % '123abc' ---
+int(0)
+--- testing: 'abc' % '123e5' ---
+int(0)
+--- testing: 'abc' % '123e5xyz' ---
+int(0)
+--- testing: 'abc' % ' 123abc' ---
+int(0)
+--- testing: 'abc' % '123 abc' ---
+int(0)
+--- testing: 'abc' % '123abc ' ---
+int(0)
+--- testing: 'abc' % '3.4a' ---
+int(0)
+--- testing: 'abc' % 'a5.9' ---
+bool(false)
+--- testing: '123abc' % '0' ---
+bool(false)
+--- testing: '123abc' % '65' ---
+int(58)
+--- testing: '123abc' % '-44' ---
+int(35)
+--- testing: '123abc' % '1.2' ---
+int(0)
+--- testing: '123abc' % '-7.7' ---
+int(4)
+--- testing: '123abc' % 'abc' ---
+bool(false)
+--- testing: '123abc' % '123abc' ---
+int(0)
+--- testing: '123abc' % '123e5' ---
+int(0)
+--- testing: '123abc' % '123e5xyz' ---
+int(0)
+--- testing: '123abc' % ' 123abc' ---
+int(0)
+--- testing: '123abc' % '123 abc' ---
+int(0)
+--- testing: '123abc' % '123abc ' ---
+int(0)
+--- testing: '123abc' % '3.4a' ---
+int(0)
+--- testing: '123abc' % 'a5.9' ---
+bool(false)
+--- testing: '123e5' % '0' ---
+bool(false)
+--- testing: '123e5' % '65' ---
+int(58)
+--- testing: '123e5' % '-44' ---
+int(35)
+--- testing: '123e5' % '1.2' ---
+int(0)
+--- testing: '123e5' % '-7.7' ---
+int(4)
+--- testing: '123e5' % 'abc' ---
+bool(false)
+--- testing: '123e5' % '123abc' ---
+int(0)
+--- testing: '123e5' % '123e5' ---
+int(0)
+--- testing: '123e5' % '123e5xyz' ---
+int(0)
+--- testing: '123e5' % ' 123abc' ---
+int(0)
+--- testing: '123e5' % '123 abc' ---
+int(0)
+--- testing: '123e5' % '123abc ' ---
+int(0)
+--- testing: '123e5' % '3.4a' ---
+int(0)
+--- testing: '123e5' % 'a5.9' ---
+bool(false)
+--- testing: '123e5xyz' % '0' ---
+bool(false)
+--- testing: '123e5xyz' % '65' ---
+int(58)
+--- testing: '123e5xyz' % '-44' ---
+int(35)
+--- testing: '123e5xyz' % '1.2' ---
+int(0)
+--- testing: '123e5xyz' % '-7.7' ---
+int(4)
+--- testing: '123e5xyz' % 'abc' ---
+bool(false)
+--- testing: '123e5xyz' % '123abc' ---
+int(0)
+--- testing: '123e5xyz' % '123e5' ---
+int(0)
+--- testing: '123e5xyz' % '123e5xyz' ---
+int(0)
+--- testing: '123e5xyz' % ' 123abc' ---
+int(0)
+--- testing: '123e5xyz' % '123 abc' ---
+int(0)
+--- testing: '123e5xyz' % '123abc ' ---
+int(0)
+--- testing: '123e5xyz' % '3.4a' ---
+int(0)
+--- testing: '123e5xyz' % 'a5.9' ---
+bool(false)
+--- testing: ' 123abc' % '0' ---
+bool(false)
+--- testing: ' 123abc' % '65' ---
+int(58)
+--- testing: ' 123abc' % '-44' ---
+int(35)
+--- testing: ' 123abc' % '1.2' ---
+int(0)
+--- testing: ' 123abc' % '-7.7' ---
+int(4)
+--- testing: ' 123abc' % 'abc' ---
+bool(false)
+--- testing: ' 123abc' % '123abc' ---
+int(0)
+--- testing: ' 123abc' % '123e5' ---
+int(0)
+--- testing: ' 123abc' % '123e5xyz' ---
+int(0)
+--- testing: ' 123abc' % ' 123abc' ---
+int(0)
+--- testing: ' 123abc' % '123 abc' ---
+int(0)
+--- testing: ' 123abc' % '123abc ' ---
+int(0)
+--- testing: ' 123abc' % '3.4a' ---
+int(0)
+--- testing: ' 123abc' % 'a5.9' ---
+bool(false)
+--- testing: '123 abc' % '0' ---
+bool(false)
+--- testing: '123 abc' % '65' ---
+int(58)
+--- testing: '123 abc' % '-44' ---
+int(35)
+--- testing: '123 abc' % '1.2' ---
+int(0)
+--- testing: '123 abc' % '-7.7' ---
+int(4)
+--- testing: '123 abc' % 'abc' ---
+bool(false)
+--- testing: '123 abc' % '123abc' ---
+int(0)
+--- testing: '123 abc' % '123e5' ---
+int(0)
+--- testing: '123 abc' % '123e5xyz' ---
+int(0)
+--- testing: '123 abc' % ' 123abc' ---
+int(0)
+--- testing: '123 abc' % '123 abc' ---
+int(0)
+--- testing: '123 abc' % '123abc ' ---
+int(0)
+--- testing: '123 abc' % '3.4a' ---
+int(0)
+--- testing: '123 abc' % 'a5.9' ---
+bool(false)
+--- testing: '123abc ' % '0' ---
+bool(false)
+--- testing: '123abc ' % '65' ---
+int(58)
+--- testing: '123abc ' % '-44' ---
+int(35)
+--- testing: '123abc ' % '1.2' ---
+int(0)
+--- testing: '123abc ' % '-7.7' ---
+int(4)
+--- testing: '123abc ' % 'abc' ---
+bool(false)
+--- testing: '123abc ' % '123abc' ---
+int(0)
+--- testing: '123abc ' % '123e5' ---
+int(0)
+--- testing: '123abc ' % '123e5xyz' ---
+int(0)
+--- testing: '123abc ' % ' 123abc' ---
+int(0)
+--- testing: '123abc ' % '123 abc' ---
+int(0)
+--- testing: '123abc ' % '123abc ' ---
+int(0)
+--- testing: '123abc ' % '3.4a' ---
+int(0)
+--- testing: '123abc ' % 'a5.9' ---
+bool(false)
+--- testing: '3.4a' % '0' ---
+bool(false)
+--- testing: '3.4a' % '65' ---
+int(3)
+--- testing: '3.4a' % '-44' ---
+int(3)
+--- testing: '3.4a' % '1.2' ---
+int(0)
+--- testing: '3.4a' % '-7.7' ---
+int(3)
+--- testing: '3.4a' % 'abc' ---
+bool(false)
+--- testing: '3.4a' % '123abc' ---
+int(3)
+--- testing: '3.4a' % '123e5' ---
+int(3)
+--- testing: '3.4a' % '123e5xyz' ---
+int(3)
+--- testing: '3.4a' % ' 123abc' ---
+int(3)
+--- testing: '3.4a' % '123 abc' ---
+int(3)
+--- testing: '3.4a' % '123abc ' ---
+int(3)
+--- testing: '3.4a' % '3.4a' ---
+int(0)
+--- testing: '3.4a' % 'a5.9' ---
+bool(false)
+--- testing: 'a5.9' % '0' ---
+bool(false)
+--- testing: 'a5.9' % '65' ---
+int(0)
+--- testing: 'a5.9' % '-44' ---
+int(0)
+--- testing: 'a5.9' % '1.2' ---
+int(0)
+--- testing: 'a5.9' % '-7.7' ---
+int(0)
+--- testing: 'a5.9' % 'abc' ---
+bool(false)
+--- testing: 'a5.9' % '123abc' ---
+int(0)
+--- testing: 'a5.9' % '123e5' ---
+int(0)
+--- testing: 'a5.9' % '123e5xyz' ---
+int(0)
+--- testing: 'a5.9' % ' 123abc' ---
+int(0)
+--- testing: 'a5.9' % '123 abc' ---
+int(0)
+--- testing: 'a5.9' % '123abc ' ---
+int(0)
+--- testing: 'a5.9' % '3.4a' ---
+int(0)
+--- testing: 'a5.9' % 'a5.9' ---
+bool(false)
+===DONE===
diff --git a/tests/lang/operators/multiply_basiclong_64bit.phpt b/tests/lang/operators/multiply_basiclong_64bit.phpt
new file mode 100644
index 0000000000..4c7077bf3b
--- /dev/null
+++ b/tests/lang/operators/multiply_basiclong_64bit.phpt
@@ -0,0 +1,582 @@
+--TEST--
+Test * operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
+
+error_reporting(E_ERROR);
+
+foreach ($longVals as $longVal) {
+ foreach($otherVals as $otherVal) {
+ echo "--- testing: $longVal * $otherVal ---\n";
+ var_dump($longVal*$otherVal);
+ }
+}
+
+foreach ($otherVals as $otherVal) {
+ foreach($longVals as $longVal) {
+ echo "--- testing: $otherVal * $longVal ---\n";
+ var_dump($otherVal*$longVal);
+ }
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 * 0 ---
+int(0)
+--- testing: 9223372036854775807 * 1 ---
+int(9223372036854775807)
+--- testing: 9223372036854775807 * -1 ---
+int(-9223372036854775807)
+--- testing: 9223372036854775807 * 7 ---
+float(6.4563604257983E+19)
+--- testing: 9223372036854775807 * 9 ---
+float(8.3010348331693E+19)
+--- testing: 9223372036854775807 * 65 ---
+float(5.9951918239556E+20)
+--- testing: 9223372036854775807 * -44 ---
+float(-4.0582836962161E+20)
+--- testing: 9223372036854775807 * 2147483647 ---
+float(1.9807040619343E+28)
+--- testing: 9223372036854775807 * 9223372036854775807 ---
+float(8.5070591730235E+37)
+--- testing: -9223372036854775808 * 0 ---
+int(0)
+--- testing: -9223372036854775808 * 1 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775808 * -1 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775808 * 7 ---
+float(-6.4563604257983E+19)
+--- testing: -9223372036854775808 * 9 ---
+float(-8.3010348331693E+19)
+--- testing: -9223372036854775808 * 65 ---
+float(-5.9951918239556E+20)
+--- testing: -9223372036854775808 * -44 ---
+float(4.0582836962161E+20)
+--- testing: -9223372036854775808 * 2147483647 ---
+float(-1.9807040619343E+28)
+--- testing: -9223372036854775808 * 9223372036854775807 ---
+float(-8.5070591730235E+37)
+--- testing: 2147483647 * 0 ---
+int(0)
+--- testing: 2147483647 * 1 ---
+int(2147483647)
+--- testing: 2147483647 * -1 ---
+int(-2147483647)
+--- testing: 2147483647 * 7 ---
+int(15032385529)
+--- testing: 2147483647 * 9 ---
+int(19327352823)
+--- testing: 2147483647 * 65 ---
+int(139586437055)
+--- testing: 2147483647 * -44 ---
+int(-94489280468)
+--- testing: 2147483647 * 2147483647 ---
+int(4611686014132420609)
+--- testing: 2147483647 * 9223372036854775807 ---
+float(1.9807040619343E+28)
+--- testing: -2147483648 * 0 ---
+int(0)
+--- testing: -2147483648 * 1 ---
+int(-2147483648)
+--- testing: -2147483648 * -1 ---
+int(2147483648)
+--- testing: -2147483648 * 7 ---
+int(-15032385536)
+--- testing: -2147483648 * 9 ---
+int(-19327352832)
+--- testing: -2147483648 * 65 ---
+int(-139586437120)
+--- testing: -2147483648 * -44 ---
+int(94489280512)
+--- testing: -2147483648 * 2147483647 ---
+int(-4611686016279904256)
+--- testing: -2147483648 * 9223372036854775807 ---
+float(-1.9807040628566E+28)
+--- testing: 9223372034707292160 * 0 ---
+int(0)
+--- testing: 9223372034707292160 * 1 ---
+int(9223372034707292160)
+--- testing: 9223372034707292160 * -1 ---
+int(-9223372034707292160)
+--- testing: 9223372034707292160 * 7 ---
+float(6.4563604242951E+19)
+--- testing: 9223372034707292160 * 9 ---
+float(8.3010348312366E+19)
+--- testing: 9223372034707292160 * 65 ---
+float(5.9951918225597E+20)
+--- testing: 9223372034707292160 * -44 ---
+float(-4.0582836952712E+20)
+--- testing: 9223372034707292160 * 2147483647 ---
+float(1.9807040614731E+28)
+--- testing: 9223372034707292160 * 9223372036854775807 ---
+float(8.5070591710428E+37)
+--- testing: -9223372034707292160 * 0 ---
+int(0)
+--- testing: -9223372034707292160 * 1 ---
+int(-9223372034707292160)
+--- testing: -9223372034707292160 * -1 ---
+int(9223372034707292160)
+--- testing: -9223372034707292160 * 7 ---
+float(-6.4563604242951E+19)
+--- testing: -9223372034707292160 * 9 ---
+float(-8.3010348312366E+19)
+--- testing: -9223372034707292160 * 65 ---
+float(-5.9951918225597E+20)
+--- testing: -9223372034707292160 * -44 ---
+float(4.0582836952712E+20)
+--- testing: -9223372034707292160 * 2147483647 ---
+float(-1.9807040614731E+28)
+--- testing: -9223372034707292160 * 9223372036854775807 ---
+float(-8.5070591710428E+37)
+--- testing: 2147483648 * 0 ---
+int(0)
+--- testing: 2147483648 * 1 ---
+int(2147483648)
+--- testing: 2147483648 * -1 ---
+int(-2147483648)
+--- testing: 2147483648 * 7 ---
+int(15032385536)
+--- testing: 2147483648 * 9 ---
+int(19327352832)
+--- testing: 2147483648 * 65 ---
+int(139586437120)
+--- testing: 2147483648 * -44 ---
+int(-94489280512)
+--- testing: 2147483648 * 2147483647 ---
+int(4611686016279904256)
+--- testing: 2147483648 * 9223372036854775807 ---
+float(1.9807040628566E+28)
+--- testing: -2147483649 * 0 ---
+int(0)
+--- testing: -2147483649 * 1 ---
+int(-2147483649)
+--- testing: -2147483649 * -1 ---
+int(2147483649)
+--- testing: -2147483649 * 7 ---
+int(-15032385543)
+--- testing: -2147483649 * 9 ---
+int(-19327352841)
+--- testing: -2147483649 * 65 ---
+int(-139586437185)
+--- testing: -2147483649 * -44 ---
+int(94489280556)
+--- testing: -2147483649 * 2147483647 ---
+int(-4611686018427387903)
+--- testing: -2147483649 * 9223372036854775807 ---
+float(-1.9807040637789E+28)
+--- testing: 4294967294 * 0 ---
+int(0)
+--- testing: 4294967294 * 1 ---
+int(4294967294)
+--- testing: 4294967294 * -1 ---
+int(-4294967294)
+--- testing: 4294967294 * 7 ---
+int(30064771058)
+--- testing: 4294967294 * 9 ---
+int(38654705646)
+--- testing: 4294967294 * 65 ---
+int(279172874110)
+--- testing: 4294967294 * -44 ---
+int(-188978560936)
+--- testing: 4294967294 * 2147483647 ---
+int(9223372028264841218)
+--- testing: 4294967294 * 9223372036854775807 ---
+float(3.9614081238685E+28)
+--- testing: 4294967295 * 0 ---
+int(0)
+--- testing: 4294967295 * 1 ---
+int(4294967295)
+--- testing: 4294967295 * -1 ---
+int(-4294967295)
+--- testing: 4294967295 * 7 ---
+int(30064771065)
+--- testing: 4294967295 * 9 ---
+int(38654705655)
+--- testing: 4294967295 * 65 ---
+int(279172874175)
+--- testing: 4294967295 * -44 ---
+int(-188978560980)
+--- testing: 4294967295 * 2147483647 ---
+int(9223372030412324865)
+--- testing: 4294967295 * 9223372036854775807 ---
+float(3.9614081247909E+28)
+--- testing: 4294967293 * 0 ---
+int(0)
+--- testing: 4294967293 * 1 ---
+int(4294967293)
+--- testing: 4294967293 * -1 ---
+int(-4294967293)
+--- testing: 4294967293 * 7 ---
+int(30064771051)
+--- testing: 4294967293 * 9 ---
+int(38654705637)
+--- testing: 4294967293 * 65 ---
+int(279172874045)
+--- testing: 4294967293 * -44 ---
+int(-188978560892)
+--- testing: 4294967293 * 2147483647 ---
+int(9223372026117357571)
+--- testing: 4294967293 * 9223372036854775807 ---
+float(3.9614081229462E+28)
+--- testing: 9223372036854775806 * 0 ---
+int(0)
+--- testing: 9223372036854775806 * 1 ---
+int(9223372036854775806)
+--- testing: 9223372036854775806 * -1 ---
+int(-9223372036854775806)
+--- testing: 9223372036854775806 * 7 ---
+float(6.4563604257983E+19)
+--- testing: 9223372036854775806 * 9 ---
+float(8.3010348331693E+19)
+--- testing: 9223372036854775806 * 65 ---
+float(5.9951918239556E+20)
+--- testing: 9223372036854775806 * -44 ---
+float(-4.0582836962161E+20)
+--- testing: 9223372036854775806 * 2147483647 ---
+float(1.9807040619343E+28)
+--- testing: 9223372036854775806 * 9223372036854775807 ---
+float(8.5070591730235E+37)
+--- testing: 9.2233720368548E+18 * 0 ---
+float(0)
+--- testing: 9.2233720368548E+18 * 1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 * -1 ---
+float(-9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 * 7 ---
+float(6.4563604257983E+19)
+--- testing: 9.2233720368548E+18 * 9 ---
+float(8.3010348331693E+19)
+--- testing: 9.2233720368548E+18 * 65 ---
+float(5.9951918239556E+20)
+--- testing: 9.2233720368548E+18 * -44 ---
+float(-4.0582836962161E+20)
+--- testing: 9.2233720368548E+18 * 2147483647 ---
+float(1.9807040619343E+28)
+--- testing: 9.2233720368548E+18 * 9223372036854775807 ---
+float(8.5070591730235E+37)
+--- testing: -9223372036854775807 * 0 ---
+int(0)
+--- testing: -9223372036854775807 * 1 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775807 * -1 ---
+int(9223372036854775807)
+--- testing: -9223372036854775807 * 7 ---
+float(-6.4563604257983E+19)
+--- testing: -9223372036854775807 * 9 ---
+float(-8.3010348331693E+19)
+--- testing: -9223372036854775807 * 65 ---
+float(-5.9951918239556E+20)
+--- testing: -9223372036854775807 * -44 ---
+float(4.0582836962161E+20)
+--- testing: -9223372036854775807 * 2147483647 ---
+float(-1.9807040619343E+28)
+--- testing: -9223372036854775807 * 9223372036854775807 ---
+float(-8.5070591730235E+37)
+--- testing: -9.2233720368548E+18 * 0 ---
+float(-0)
+--- testing: -9.2233720368548E+18 * 1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 * -1 ---
+float(9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 * 7 ---
+float(-6.4563604257983E+19)
+--- testing: -9.2233720368548E+18 * 9 ---
+float(-8.3010348331693E+19)
+--- testing: -9.2233720368548E+18 * 65 ---
+float(-5.9951918239556E+20)
+--- testing: -9.2233720368548E+18 * -44 ---
+float(4.0582836962161E+20)
+--- testing: -9.2233720368548E+18 * 2147483647 ---
+float(-1.9807040619343E+28)
+--- testing: -9.2233720368548E+18 * 9223372036854775807 ---
+float(-8.5070591730235E+37)
+--- testing: 0 * 9223372036854775807 ---
+int(0)
+--- testing: 0 * -9223372036854775808 ---
+int(0)
+--- testing: 0 * 2147483647 ---
+int(0)
+--- testing: 0 * -2147483648 ---
+int(0)
+--- testing: 0 * 9223372034707292160 ---
+int(0)
+--- testing: 0 * -9223372034707292160 ---
+int(0)
+--- testing: 0 * 2147483648 ---
+int(0)
+--- testing: 0 * -2147483649 ---
+int(0)
+--- testing: 0 * 4294967294 ---
+int(0)
+--- testing: 0 * 4294967295 ---
+int(0)
+--- testing: 0 * 4294967293 ---
+int(0)
+--- testing: 0 * 9223372036854775806 ---
+int(0)
+--- testing: 0 * 9.2233720368548E+18 ---
+float(0)
+--- testing: 0 * -9223372036854775807 ---
+int(0)
+--- testing: 0 * -9.2233720368548E+18 ---
+float(-0)
+--- testing: 1 * 9223372036854775807 ---
+int(9223372036854775807)
+--- testing: 1 * -9223372036854775808 ---
+int(-9223372036854775808)
+--- testing: 1 * 2147483647 ---
+int(2147483647)
+--- testing: 1 * -2147483648 ---
+int(-2147483648)
+--- testing: 1 * 9223372034707292160 ---
+int(9223372034707292160)
+--- testing: 1 * -9223372034707292160 ---
+int(-9223372034707292160)
+--- testing: 1 * 2147483648 ---
+int(2147483648)
+--- testing: 1 * -2147483649 ---
+int(-2147483649)
+--- testing: 1 * 4294967294 ---
+int(4294967294)
+--- testing: 1 * 4294967295 ---
+int(4294967295)
+--- testing: 1 * 4294967293 ---
+int(4294967293)
+--- testing: 1 * 9223372036854775806 ---
+int(9223372036854775806)
+--- testing: 1 * 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 1 * -9223372036854775807 ---
+int(-9223372036854775807)
+--- testing: 1 * -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -1 * 9223372036854775807 ---
+int(-9223372036854775807)
+--- testing: -1 * -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: -1 * 2147483647 ---
+int(-2147483647)
+--- testing: -1 * -2147483648 ---
+int(2147483648)
+--- testing: -1 * 9223372034707292160 ---
+int(-9223372034707292160)
+--- testing: -1 * -9223372034707292160 ---
+int(9223372034707292160)
+--- testing: -1 * 2147483648 ---
+int(-2147483648)
+--- testing: -1 * -2147483649 ---
+int(2147483649)
+--- testing: -1 * 4294967294 ---
+int(-4294967294)
+--- testing: -1 * 4294967295 ---
+int(-4294967295)
+--- testing: -1 * 4294967293 ---
+int(-4294967293)
+--- testing: -1 * 9223372036854775806 ---
+int(-9223372036854775806)
+--- testing: -1 * 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -1 * -9223372036854775807 ---
+int(9223372036854775807)
+--- testing: -1 * -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 7 * 9223372036854775807 ---
+float(6.4563604257983E+19)
+--- testing: 7 * -9223372036854775808 ---
+float(-6.4563604257983E+19)
+--- testing: 7 * 2147483647 ---
+int(15032385529)
+--- testing: 7 * -2147483648 ---
+int(-15032385536)
+--- testing: 7 * 9223372034707292160 ---
+float(6.4563604242951E+19)
+--- testing: 7 * -9223372034707292160 ---
+float(-6.4563604242951E+19)
+--- testing: 7 * 2147483648 ---
+int(15032385536)
+--- testing: 7 * -2147483649 ---
+int(-15032385543)
+--- testing: 7 * 4294967294 ---
+int(30064771058)
+--- testing: 7 * 4294967295 ---
+int(30064771065)
+--- testing: 7 * 4294967293 ---
+int(30064771051)
+--- testing: 7 * 9223372036854775806 ---
+float(6.4563604257983E+19)
+--- testing: 7 * 9.2233720368548E+18 ---
+float(6.4563604257983E+19)
+--- testing: 7 * -9223372036854775807 ---
+float(-6.4563604257983E+19)
+--- testing: 7 * -9.2233720368548E+18 ---
+float(-6.4563604257983E+19)
+--- testing: 9 * 9223372036854775807 ---
+float(8.3010348331693E+19)
+--- testing: 9 * -9223372036854775808 ---
+float(-8.3010348331693E+19)
+--- testing: 9 * 2147483647 ---
+int(19327352823)
+--- testing: 9 * -2147483648 ---
+int(-19327352832)
+--- testing: 9 * 9223372034707292160 ---
+float(8.3010348312366E+19)
+--- testing: 9 * -9223372034707292160 ---
+float(-8.3010348312366E+19)
+--- testing: 9 * 2147483648 ---
+int(19327352832)
+--- testing: 9 * -2147483649 ---
+int(-19327352841)
+--- testing: 9 * 4294967294 ---
+int(38654705646)
+--- testing: 9 * 4294967295 ---
+int(38654705655)
+--- testing: 9 * 4294967293 ---
+int(38654705637)
+--- testing: 9 * 9223372036854775806 ---
+float(8.3010348331693E+19)
+--- testing: 9 * 9.2233720368548E+18 ---
+float(8.3010348331693E+19)
+--- testing: 9 * -9223372036854775807 ---
+float(-8.3010348331693E+19)
+--- testing: 9 * -9.2233720368548E+18 ---
+float(-8.3010348331693E+19)
+--- testing: 65 * 9223372036854775807 ---
+float(5.9951918239556E+20)
+--- testing: 65 * -9223372036854775808 ---
+float(-5.9951918239556E+20)
+--- testing: 65 * 2147483647 ---
+int(139586437055)
+--- testing: 65 * -2147483648 ---
+int(-139586437120)
+--- testing: 65 * 9223372034707292160 ---
+float(5.9951918225597E+20)
+--- testing: 65 * -9223372034707292160 ---
+float(-5.9951918225597E+20)
+--- testing: 65 * 2147483648 ---
+int(139586437120)
+--- testing: 65 * -2147483649 ---
+int(-139586437185)
+--- testing: 65 * 4294967294 ---
+int(279172874110)
+--- testing: 65 * 4294967295 ---
+int(279172874175)
+--- testing: 65 * 4294967293 ---
+int(279172874045)
+--- testing: 65 * 9223372036854775806 ---
+float(5.9951918239556E+20)
+--- testing: 65 * 9.2233720368548E+18 ---
+float(5.9951918239556E+20)
+--- testing: 65 * -9223372036854775807 ---
+float(-5.9951918239556E+20)
+--- testing: 65 * -9.2233720368548E+18 ---
+float(-5.9951918239556E+20)
+--- testing: -44 * 9223372036854775807 ---
+float(-4.0582836962161E+20)
+--- testing: -44 * -9223372036854775808 ---
+float(4.0582836962161E+20)
+--- testing: -44 * 2147483647 ---
+int(-94489280468)
+--- testing: -44 * -2147483648 ---
+int(94489280512)
+--- testing: -44 * 9223372034707292160 ---
+float(-4.0582836952712E+20)
+--- testing: -44 * -9223372034707292160 ---
+float(4.0582836952712E+20)
+--- testing: -44 * 2147483648 ---
+int(-94489280512)
+--- testing: -44 * -2147483649 ---
+int(94489280556)
+--- testing: -44 * 4294967294 ---
+int(-188978560936)
+--- testing: -44 * 4294967295 ---
+int(-188978560980)
+--- testing: -44 * 4294967293 ---
+int(-188978560892)
+--- testing: -44 * 9223372036854775806 ---
+float(-4.0582836962161E+20)
+--- testing: -44 * 9.2233720368548E+18 ---
+float(-4.0582836962161E+20)
+--- testing: -44 * -9223372036854775807 ---
+float(4.0582836962161E+20)
+--- testing: -44 * -9.2233720368548E+18 ---
+float(4.0582836962161E+20)
+--- testing: 2147483647 * 9223372036854775807 ---
+float(1.9807040619343E+28)
+--- testing: 2147483647 * -9223372036854775808 ---
+float(-1.9807040619343E+28)
+--- testing: 2147483647 * 2147483647 ---
+int(4611686014132420609)
+--- testing: 2147483647 * -2147483648 ---
+int(-4611686016279904256)
+--- testing: 2147483647 * 9223372034707292160 ---
+float(1.9807040614731E+28)
+--- testing: 2147483647 * -9223372034707292160 ---
+float(-1.9807040614731E+28)
+--- testing: 2147483647 * 2147483648 ---
+int(4611686016279904256)
+--- testing: 2147483647 * -2147483649 ---
+int(-4611686018427387903)
+--- testing: 2147483647 * 4294967294 ---
+int(9223372028264841218)
+--- testing: 2147483647 * 4294967295 ---
+int(9223372030412324865)
+--- testing: 2147483647 * 4294967293 ---
+int(9223372026117357571)
+--- testing: 2147483647 * 9223372036854775806 ---
+float(1.9807040619343E+28)
+--- testing: 2147483647 * 9.2233720368548E+18 ---
+float(1.9807040619343E+28)
+--- testing: 2147483647 * -9223372036854775807 ---
+float(-1.9807040619343E+28)
+--- testing: 2147483647 * -9.2233720368548E+18 ---
+float(-1.9807040619343E+28)
+--- testing: 9223372036854775807 * 9223372036854775807 ---
+float(8.5070591730235E+37)
+--- testing: 9223372036854775807 * -9223372036854775808 ---
+float(-8.5070591730235E+37)
+--- testing: 9223372036854775807 * 2147483647 ---
+float(1.9807040619343E+28)
+--- testing: 9223372036854775807 * -2147483648 ---
+float(-1.9807040628566E+28)
+--- testing: 9223372036854775807 * 9223372034707292160 ---
+float(8.5070591710428E+37)
+--- testing: 9223372036854775807 * -9223372034707292160 ---
+float(-8.5070591710428E+37)
+--- testing: 9223372036854775807 * 2147483648 ---
+float(1.9807040628566E+28)
+--- testing: 9223372036854775807 * -2147483649 ---
+float(-1.9807040637789E+28)
+--- testing: 9223372036854775807 * 4294967294 ---
+float(3.9614081238685E+28)
+--- testing: 9223372036854775807 * 4294967295 ---
+float(3.9614081247909E+28)
+--- testing: 9223372036854775807 * 4294967293 ---
+float(3.9614081229462E+28)
+--- testing: 9223372036854775807 * 9223372036854775806 ---
+float(8.5070591730235E+37)
+--- testing: 9223372036854775807 * 9.2233720368548E+18 ---
+float(8.5070591730235E+37)
+--- testing: 9223372036854775807 * -9223372036854775807 ---
+float(-8.5070591730235E+37)
+--- testing: 9223372036854775807 * -9.2233720368548E+18 ---
+float(-8.5070591730235E+37)
+===DONE===
diff --git a/tests/lang/operators/multiply_variationStr.phpt b/tests/lang/operators/multiply_variationStr.phpt
new file mode 100644
index 0000000000..30d5f79f1a
--- /dev/null
+++ b/tests/lang/operators/multiply_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test * operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' * '$otherVal' ---\n";
+ var_dump($strVal*$otherVal);
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' * '0' ---
+int(0)
+--- testing: '0' * '65' ---
+int(0)
+--- testing: '0' * '-44' ---
+int(0)
+--- testing: '0' * '1.2' ---
+float(0)
+--- testing: '0' * '-7.7' ---
+float(-0)
+--- testing: '0' * 'abc' ---
+int(0)
+--- testing: '0' * '123abc' ---
+int(0)
+--- testing: '0' * '123e5' ---
+float(0)
+--- testing: '0' * '123e5xyz' ---
+float(0)
+--- testing: '0' * ' 123abc' ---
+int(0)
+--- testing: '0' * '123 abc' ---
+int(0)
+--- testing: '0' * '123abc ' ---
+int(0)
+--- testing: '0' * '3.4a' ---
+float(0)
+--- testing: '0' * 'a5.9' ---
+int(0)
+--- testing: '65' * '0' ---
+int(0)
+--- testing: '65' * '65' ---
+int(4225)
+--- testing: '65' * '-44' ---
+int(-2860)
+--- testing: '65' * '1.2' ---
+float(78)
+--- testing: '65' * '-7.7' ---
+float(-500.5)
+--- testing: '65' * 'abc' ---
+int(0)
+--- testing: '65' * '123abc' ---
+int(7995)
+--- testing: '65' * '123e5' ---
+float(799500000)
+--- testing: '65' * '123e5xyz' ---
+float(799500000)
+--- testing: '65' * ' 123abc' ---
+int(7995)
+--- testing: '65' * '123 abc' ---
+int(7995)
+--- testing: '65' * '123abc ' ---
+int(7995)
+--- testing: '65' * '3.4a' ---
+float(221)
+--- testing: '65' * 'a5.9' ---
+int(0)
+--- testing: '-44' * '0' ---
+int(0)
+--- testing: '-44' * '65' ---
+int(-2860)
+--- testing: '-44' * '-44' ---
+int(1936)
+--- testing: '-44' * '1.2' ---
+float(-52.8)
+--- testing: '-44' * '-7.7' ---
+float(338.8)
+--- testing: '-44' * 'abc' ---
+int(0)
+--- testing: '-44' * '123abc' ---
+int(-5412)
+--- testing: '-44' * '123e5' ---
+float(-541200000)
+--- testing: '-44' * '123e5xyz' ---
+float(-541200000)
+--- testing: '-44' * ' 123abc' ---
+int(-5412)
+--- testing: '-44' * '123 abc' ---
+int(-5412)
+--- testing: '-44' * '123abc ' ---
+int(-5412)
+--- testing: '-44' * '3.4a' ---
+float(-149.6)
+--- testing: '-44' * 'a5.9' ---
+int(0)
+--- testing: '1.2' * '0' ---
+float(0)
+--- testing: '1.2' * '65' ---
+float(78)
+--- testing: '1.2' * '-44' ---
+float(-52.8)
+--- testing: '1.2' * '1.2' ---
+float(1.44)
+--- testing: '1.2' * '-7.7' ---
+float(-9.24)
+--- testing: '1.2' * 'abc' ---
+float(0)
+--- testing: '1.2' * '123abc' ---
+float(147.6)
+--- testing: '1.2' * '123e5' ---
+float(14760000)
+--- testing: '1.2' * '123e5xyz' ---
+float(14760000)
+--- testing: '1.2' * ' 123abc' ---
+float(147.6)
+--- testing: '1.2' * '123 abc' ---
+float(147.6)
+--- testing: '1.2' * '123abc ' ---
+float(147.6)
+--- testing: '1.2' * '3.4a' ---
+float(4.08)
+--- testing: '1.2' * 'a5.9' ---
+float(0)
+--- testing: '-7.7' * '0' ---
+float(-0)
+--- testing: '-7.7' * '65' ---
+float(-500.5)
+--- testing: '-7.7' * '-44' ---
+float(338.8)
+--- testing: '-7.7' * '1.2' ---
+float(-9.24)
+--- testing: '-7.7' * '-7.7' ---
+float(59.29)
+--- testing: '-7.7' * 'abc' ---
+float(-0)
+--- testing: '-7.7' * '123abc' ---
+float(-947.1)
+--- testing: '-7.7' * '123e5' ---
+float(-94710000)
+--- testing: '-7.7' * '123e5xyz' ---
+float(-94710000)
+--- testing: '-7.7' * ' 123abc' ---
+float(-947.1)
+--- testing: '-7.7' * '123 abc' ---
+float(-947.1)
+--- testing: '-7.7' * '123abc ' ---
+float(-947.1)
+--- testing: '-7.7' * '3.4a' ---
+float(-26.18)
+--- testing: '-7.7' * 'a5.9' ---
+float(-0)
+--- testing: 'abc' * '0' ---
+int(0)
+--- testing: 'abc' * '65' ---
+int(0)
+--- testing: 'abc' * '-44' ---
+int(0)
+--- testing: 'abc' * '1.2' ---
+float(0)
+--- testing: 'abc' * '-7.7' ---
+float(-0)
+--- testing: 'abc' * 'abc' ---
+int(0)
+--- testing: 'abc' * '123abc' ---
+int(0)
+--- testing: 'abc' * '123e5' ---
+float(0)
+--- testing: 'abc' * '123e5xyz' ---
+float(0)
+--- testing: 'abc' * ' 123abc' ---
+int(0)
+--- testing: 'abc' * '123 abc' ---
+int(0)
+--- testing: 'abc' * '123abc ' ---
+int(0)
+--- testing: 'abc' * '3.4a' ---
+float(0)
+--- testing: 'abc' * 'a5.9' ---
+int(0)
+--- testing: '123abc' * '0' ---
+int(0)
+--- testing: '123abc' * '65' ---
+int(7995)
+--- testing: '123abc' * '-44' ---
+int(-5412)
+--- testing: '123abc' * '1.2' ---
+float(147.6)
+--- testing: '123abc' * '-7.7' ---
+float(-947.1)
+--- testing: '123abc' * 'abc' ---
+int(0)
+--- testing: '123abc' * '123abc' ---
+int(15129)
+--- testing: '123abc' * '123e5' ---
+float(1512900000)
+--- testing: '123abc' * '123e5xyz' ---
+float(1512900000)
+--- testing: '123abc' * ' 123abc' ---
+int(15129)
+--- testing: '123abc' * '123 abc' ---
+int(15129)
+--- testing: '123abc' * '123abc ' ---
+int(15129)
+--- testing: '123abc' * '3.4a' ---
+float(418.2)
+--- testing: '123abc' * 'a5.9' ---
+int(0)
+--- testing: '123e5' * '0' ---
+float(0)
+--- testing: '123e5' * '65' ---
+float(799500000)
+--- testing: '123e5' * '-44' ---
+float(-541200000)
+--- testing: '123e5' * '1.2' ---
+float(14760000)
+--- testing: '123e5' * '-7.7' ---
+float(-94710000)
+--- testing: '123e5' * 'abc' ---
+float(0)
+--- testing: '123e5' * '123abc' ---
+float(1512900000)
+--- testing: '123e5' * '123e5' ---
+float(1.5129E+14)
+--- testing: '123e5' * '123e5xyz' ---
+float(1.5129E+14)
+--- testing: '123e5' * ' 123abc' ---
+float(1512900000)
+--- testing: '123e5' * '123 abc' ---
+float(1512900000)
+--- testing: '123e5' * '123abc ' ---
+float(1512900000)
+--- testing: '123e5' * '3.4a' ---
+float(41820000)
+--- testing: '123e5' * 'a5.9' ---
+float(0)
+--- testing: '123e5xyz' * '0' ---
+float(0)
+--- testing: '123e5xyz' * '65' ---
+float(799500000)
+--- testing: '123e5xyz' * '-44' ---
+float(-541200000)
+--- testing: '123e5xyz' * '1.2' ---
+float(14760000)
+--- testing: '123e5xyz' * '-7.7' ---
+float(-94710000)
+--- testing: '123e5xyz' * 'abc' ---
+float(0)
+--- testing: '123e5xyz' * '123abc' ---
+float(1512900000)
+--- testing: '123e5xyz' * '123e5' ---
+float(1.5129E+14)
+--- testing: '123e5xyz' * '123e5xyz' ---
+float(1.5129E+14)
+--- testing: '123e5xyz' * ' 123abc' ---
+float(1512900000)
+--- testing: '123e5xyz' * '123 abc' ---
+float(1512900000)
+--- testing: '123e5xyz' * '123abc ' ---
+float(1512900000)
+--- testing: '123e5xyz' * '3.4a' ---
+float(41820000)
+--- testing: '123e5xyz' * 'a5.9' ---
+float(0)
+--- testing: ' 123abc' * '0' ---
+int(0)
+--- testing: ' 123abc' * '65' ---
+int(7995)
+--- testing: ' 123abc' * '-44' ---
+int(-5412)
+--- testing: ' 123abc' * '1.2' ---
+float(147.6)
+--- testing: ' 123abc' * '-7.7' ---
+float(-947.1)
+--- testing: ' 123abc' * 'abc' ---
+int(0)
+--- testing: ' 123abc' * '123abc' ---
+int(15129)
+--- testing: ' 123abc' * '123e5' ---
+float(1512900000)
+--- testing: ' 123abc' * '123e5xyz' ---
+float(1512900000)
+--- testing: ' 123abc' * ' 123abc' ---
+int(15129)
+--- testing: ' 123abc' * '123 abc' ---
+int(15129)
+--- testing: ' 123abc' * '123abc ' ---
+int(15129)
+--- testing: ' 123abc' * '3.4a' ---
+float(418.2)
+--- testing: ' 123abc' * 'a5.9' ---
+int(0)
+--- testing: '123 abc' * '0' ---
+int(0)
+--- testing: '123 abc' * '65' ---
+int(7995)
+--- testing: '123 abc' * '-44' ---
+int(-5412)
+--- testing: '123 abc' * '1.2' ---
+float(147.6)
+--- testing: '123 abc' * '-7.7' ---
+float(-947.1)
+--- testing: '123 abc' * 'abc' ---
+int(0)
+--- testing: '123 abc' * '123abc' ---
+int(15129)
+--- testing: '123 abc' * '123e5' ---
+float(1512900000)
+--- testing: '123 abc' * '123e5xyz' ---
+float(1512900000)
+--- testing: '123 abc' * ' 123abc' ---
+int(15129)
+--- testing: '123 abc' * '123 abc' ---
+int(15129)
+--- testing: '123 abc' * '123abc ' ---
+int(15129)
+--- testing: '123 abc' * '3.4a' ---
+float(418.2)
+--- testing: '123 abc' * 'a5.9' ---
+int(0)
+--- testing: '123abc ' * '0' ---
+int(0)
+--- testing: '123abc ' * '65' ---
+int(7995)
+--- testing: '123abc ' * '-44' ---
+int(-5412)
+--- testing: '123abc ' * '1.2' ---
+float(147.6)
+--- testing: '123abc ' * '-7.7' ---
+float(-947.1)
+--- testing: '123abc ' * 'abc' ---
+int(0)
+--- testing: '123abc ' * '123abc' ---
+int(15129)
+--- testing: '123abc ' * '123e5' ---
+float(1512900000)
+--- testing: '123abc ' * '123e5xyz' ---
+float(1512900000)
+--- testing: '123abc ' * ' 123abc' ---
+int(15129)
+--- testing: '123abc ' * '123 abc' ---
+int(15129)
+--- testing: '123abc ' * '123abc ' ---
+int(15129)
+--- testing: '123abc ' * '3.4a' ---
+float(418.2)
+--- testing: '123abc ' * 'a5.9' ---
+int(0)
+--- testing: '3.4a' * '0' ---
+float(0)
+--- testing: '3.4a' * '65' ---
+float(221)
+--- testing: '3.4a' * '-44' ---
+float(-149.6)
+--- testing: '3.4a' * '1.2' ---
+float(4.08)
+--- testing: '3.4a' * '-7.7' ---
+float(-26.18)
+--- testing: '3.4a' * 'abc' ---
+float(0)
+--- testing: '3.4a' * '123abc' ---
+float(418.2)
+--- testing: '3.4a' * '123e5' ---
+float(41820000)
+--- testing: '3.4a' * '123e5xyz' ---
+float(41820000)
+--- testing: '3.4a' * ' 123abc' ---
+float(418.2)
+--- testing: '3.4a' * '123 abc' ---
+float(418.2)
+--- testing: '3.4a' * '123abc ' ---
+float(418.2)
+--- testing: '3.4a' * '3.4a' ---
+float(11.56)
+--- testing: '3.4a' * 'a5.9' ---
+float(0)
+--- testing: 'a5.9' * '0' ---
+int(0)
+--- testing: 'a5.9' * '65' ---
+int(0)
+--- testing: 'a5.9' * '-44' ---
+int(0)
+--- testing: 'a5.9' * '1.2' ---
+float(0)
+--- testing: 'a5.9' * '-7.7' ---
+float(-0)
+--- testing: 'a5.9' * 'abc' ---
+int(0)
+--- testing: 'a5.9' * '123abc' ---
+int(0)
+--- testing: 'a5.9' * '123e5' ---
+float(0)
+--- testing: 'a5.9' * '123e5xyz' ---
+float(0)
+--- testing: 'a5.9' * ' 123abc' ---
+int(0)
+--- testing: 'a5.9' * '123 abc' ---
+int(0)
+--- testing: 'a5.9' * '123abc ' ---
+int(0)
+--- testing: 'a5.9' * '3.4a' ---
+float(0)
+--- testing: 'a5.9' * 'a5.9' ---
+int(0)
+===DONE===
diff --git a/tests/lang/operators/negate_basiclong_64bit.phpt b/tests/lang/operators/negate_basiclong_64bit.phpt
new file mode 100644
index 0000000000..e0cf10da69
--- /dev/null
+++ b/tests/lang/operators/negate_basiclong_64bit.phpt
@@ -0,0 +1,60 @@
+--TEST--
+Test -N operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+
+foreach ($longVals as $longVal) {
+ echo "--- testing: $longVal ---\n";
+ var_dump(-$longVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 2147483647 ---
+int(-2147483647)
+--- testing: -2147483648 ---
+int(2147483648)
+--- testing: 9223372034707292160 ---
+int(-9223372034707292160)
+--- testing: -9223372034707292160 ---
+int(9223372034707292160)
+--- testing: 2147483648 ---
+int(-2147483648)
+--- testing: -2147483649 ---
+int(2147483649)
+--- testing: 4294967294 ---
+int(-4294967294)
+--- testing: 4294967295 ---
+int(-4294967295)
+--- testing: 4294967293 ---
+int(-4294967293)
+--- testing: 9223372036854775806 ---
+int(-9223372036854775806)
+--- testing: 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775807 ---
+int(9223372036854775807)
+--- testing: -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+===DONE===
diff --git a/tests/lang/operators/negate_variationStr.phpt b/tests/lang/operators/negate_variationStr.phpt
new file mode 100644
index 0000000000..a25bdda7f5
--- /dev/null
+++ b/tests/lang/operators/negate_variationStr.phpt
@@ -0,0 +1,48 @@
+--TEST--
+Test -N operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ var_dump(-$strVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+int(0)
+--- testing: '65' ---
+int(-65)
+--- testing: '-44' ---
+int(44)
+--- testing: '1.2' ---
+float(-1.2)
+--- testing: '-7.7' ---
+float(7.7)
+--- testing: 'abc' ---
+int(0)
+--- testing: '123abc' ---
+int(-123)
+--- testing: '123e5' ---
+float(-12300000)
+--- testing: '123e5xyz' ---
+float(-12300000)
+--- testing: ' 123abc' ---
+int(-123)
+--- testing: '123 abc' ---
+int(-123)
+--- testing: '123abc ' ---
+int(-123)
+--- testing: '3.4a' ---
+float(-3.4)
+--- testing: 'a5.9' ---
+int(0)
+===DONE===
diff --git a/tests/lang/operators/operator_equals_basic.phpt b/tests/lang/operators/operator_equals_basic.phpt
new file mode 100644
index 0000000000..1b42fc3db9
--- /dev/null
+++ b/tests/lang/operators/operator_equals_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test == operator : different types
+--FILE--
+<?php
+
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array("679", "679abc", " 679", "679 ", 679.0, 6.79E2, "+679", +679);
+$valid_int2 = array("-67835", "-67835abc", " -67835", "-67835 ", -67835.000, -6.7835E4);
+$invalid_int1 = array("6 7 9", "6y79", 678);
+$invalid_int2 = array("- 67835", "-67,835", "-67 835", "-678y35", -76834);
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", 5.738545835e4);
+$valid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", -6.734576567E4);
+$invalid_float1 = array("57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4);
+$invalid_float2 = array("- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4);
+
+
+$toCompare = array(
+ true, $valid_true, $valid_false,
+ false, $valid_false, $valid_true,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest == $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest == $compareVal) {
+ echo "FAILED: '$typeToTest' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_equals_variation.phpt b/tests/lang/operators/operator_equals_variation.phpt
new file mode 100644
index 0000000000..60e6abb012
--- /dev/null
+++ b/tests/lang/operators/operator_equals_variation.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test == operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$invalidEqual = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validEqual); $i +=2) {
+ $typeToTestVal = $validEqual[$i];
+ $compares = $validEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal == $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidEqual); $i +=2) {
+ $typeToTestVal = $invalidEqual[$i];
+ $compares = $invalidEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal == $compareVal) {
+ echo "FAILED: '$typeToTestVal' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_equals_variation_64bit.phpt b/tests/lang/operators/operator_equals_variation_64bit.phpt
new file mode 100644
index 0000000000..b521735479
--- /dev/null
+++ b/tests/lang/operators/operator_equals_variation_64bit.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test == operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1),
+);
+
+$invalidEqual = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit + 1),
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validEqual); $i +=2) {
+ $typeToTestVal = $validEqual[$i];
+ $compares = $validEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal == $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidEqual); $i +=2) {
+ $typeToTestVal = $invalidEqual[$i];
+ $compares = $invalidEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal == $compareVal) {
+ echo "FAILED: '$typeToTestVal' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_basic.phpt b/tests/lang/operators/operator_gt_basic.phpt
new file mode 100644
index 0000000000..06fbcee9e0
--- /dev/null
+++ b/tests/lang/operators/operator_gt_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test > operator : different types
+--FILE--
+<?php
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array("678", "678abc", " 678", "678 ", 678.0, 6.789E2, "+678", +678);
+$valid_int2 = array("-67836", "-67836abc", " -67836", "-67836 ", -67835.0001, -6.78351E4);
+$invalid_int1 = array(679, "679");
+$invalid_int2 = array(-67835, "-67835");
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385.45834", "57385.45834aaa", " 57385.45834", 5.738545834e4);
+$valid_float2 = array("-67345.76568", "-67345.76568aaa", " -67345.76568", -6.734576568E4);
+$invalid_float1 = array(57385.45835, 5.738545835e4);
+$invalid_float2 = array(-67345.76567, -6.734576567E4);
+
+
+$toCompare = array(
+// boolean test will result in both sides being converted to boolean so !0 = true and true is not > true for example
+// also note that a string of "0" is converted to false but a string of "0.0" is converted to true
+// false cannot be tested as 0 can never be > 0 or 1
+ true, $valid_false, $valid_true,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest > $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest > $compareVal) {
+ echo "FAILED: '$typeToTest' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_or_equal_basic.phpt b/tests/lang/operators/operator_gt_or_equal_basic.phpt
new file mode 100644
index 0000000000..02a561c425
--- /dev/null
+++ b/tests/lang/operators/operator_gt_or_equal_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test >= operator : different types
+--FILE--
+<?php
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array("679", "679abc", " 679", 679.0, 6.79E2, "678", "678abc", " 678", 678.0, 6.78E2, 6.789E2, "+678", +678);
+$valid_int2 = array("-67835", "-67835abc", " -67835", -67835.000, -6.7835E4, "-67836", "-67836abc". " -67836", -67835.0001, -6.78351E4, "-67836", -67835.0001, -6.78351E4);
+$invalid_int1 = array(680, "680");
+$invalid_int2 = array(-67834, "-67834");
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", 5.738545835e4, "57385.45834", "57385.45834aaa", " 57385.45834", 5.738545834e4);
+$valid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", -6.734576567E4, "-67345.76568", "-67345.76568aaa", " -67345.76568", -6.734576568E4);
+$invalid_float1 = array(57385.45836, 5.738545836e4);
+$invalid_float2 = array(-67345.76564, -6.734576564E4);
+
+$toCompare = array(
+
+ true, array_merge($valid_false, $valid_true), NULL,
+ false, $valid_false, $valid_true,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest >= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ if ($invalid_compares != NULL) {
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest >= $compareVal) {
+ echo "FAILED: '$typeToTest' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_or_equal_variation.phpt b/tests/lang/operators/operator_gt_or_equal_variation.phpt
new file mode 100644
index 0000000000..c4253b55e5
--- /dev/null
+++ b/tests/lang/operators/operator_gt_or_equal_variation.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test >= operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validGtOrEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, MIN_32Bit - 1),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$invalidGtOrEqual = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit + 1,"-2147483646", -2.1474836460001e9)
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validGtOrEqual); $i +=2) {
+ $typeToTestVal = $validGtOrEqual[$i];
+ $compares = $validGtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal >= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidGtOrEqual); $i +=2) {
+ $typeToTestVal = $invalidGtOrEqual[$i];
+ $compares = $invalidGtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal >= $compareVal) {
+ echo "FAILED: '$typeToTestVal' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt b/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt
new file mode 100644
index 0000000000..a2f7aa49ee
--- /dev/null
+++ b/tests/lang/operators/operator_gt_or_equal_variation_64bit.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test >= operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validGtOrEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, MIN_32Bit - 1),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1),
+);
+
+$invalidGtOrEqual = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit + 1,"-2147483646", -2.1474836460001e9)
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validGtOrEqual); $i +=2) {
+ $typeToTestVal = $validGtOrEqual[$i];
+ $compares = $validGtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal >= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidGtOrEqual); $i +=2) {
+ $typeToTestVal = $invalidGtOrEqual[$i];
+ $compares = $invalidGtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal >= $compareVal) {
+ echo "FAILED: '$typeToTestVal' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_variation.phpt b/tests/lang/operators/operator_gt_variation.phpt
new file mode 100644
index 0000000000..a158824da3
--- /dev/null
+++ b/tests/lang/operators/operator_gt_variation.phpt
@@ -0,0 +1,62 @@
+--TEST--
+Test > operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validGreaterThan = array (
+MAX_32Bit, array(MAX_32Bit - 1, "2147483646", "2147483646.999", 2.147483646e9, 2147483646.9, MIN_32Bit),
+-2147483647, array(MIN_32Bit, "-2147483648", "-2147483647.001", -2.1474836471e9, -2147483647.9),
+);
+
+$invalidGreaterThan = array (
+MAX_32Bit, array(2e33, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit + 1, MAX_32Bit)
+);
+
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validGreaterThan); $i +=2) {
+ $typeToTestVal = $validGreaterThan[$i];
+ $compares = $validGreaterThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal > $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidGreaterThan); $i +=2) {
+ $typeToTestVal = $invalidGreaterThan[$i];
+ $compares = $invalidGreaterThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal > $compareVal) {
+ echo "FAILED: '$typeToTestVal' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_gt_variation_64bit.phpt b/tests/lang/operators/operator_gt_variation_64bit.phpt
new file mode 100644
index 0000000000..6223e07fa5
--- /dev/null
+++ b/tests/lang/operators/operator_gt_variation_64bit.phpt
@@ -0,0 +1,62 @@
+--TEST--
+Test > operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validGreaterThan = array (
+MAX_32Bit, array(MAX_32Bit - 1, "2147483646", "2147483646.999", 2.147483646e9, 2147483646.9, MIN_32Bit),
+-2147483647, array(MIN_32Bit, "-2147483648", "-2147483647.001", -2.1474836471e9, -2147483647.9),
+);
+
+$invalidGreaterThan = array (
+MAX_32Bit, array(2e33, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit + 1, MAX_32Bit)
+);
+
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validGreaterThan); $i +=2) {
+ $typeToTestVal = $validGreaterThan[$i];
+ $compares = $validGreaterThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal > $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidGreaterThan); $i +=2) {
+ $typeToTestVal = $invalidGreaterThan[$i];
+ $compares = $invalidGreaterThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal > $compareVal) {
+ echo "FAILED: '$typeToTestVal' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_identical_basic.phpt b/tests/lang/operators/operator_identical_basic.phpt
new file mode 100644
index 0000000000..a4cd8a0702
--- /dev/null
+++ b/tests/lang/operators/operator_identical_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test === operator : different types
+--FILE--
+<?php
+
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array(679, +679);
+$valid_int2 = array(-67835);
+$invalid_int1 = array("679", "679abc", " 679", "679 ", 679.0, 6.79E2, "+679", "6 7 9", "6y79", 678);
+$invalid_int2 = array("-67835", "-67835abc", " -67835", "-67835 ", -67835.000, -6.7835E4, "- 67835", "-67,835", "-67 835", "-678y35", -76834);
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array(57385.45835, 5.738545835e4);
+$valid_float2 = array(-67345.76567, -6.734576567E4);
+$invalid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", "57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4);
+$invalid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", "- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4);
+
+
+$toCompare = array(
+ true, array(true), array_merge($valid_true, $valid_false),
+ false, array(false), array_merge($valid_true, $valid_false),
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest === $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest === $compareVal) {
+ echo "FAILED: '$typeToTest' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_identical_variation.phpt b/tests/lang/operators/operator_identical_variation.phpt
new file mode 100644
index 0000000000..76639c7bc5
--- /dev/null
+++ b/tests/lang/operators/operator_identical_variation.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test === operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validIdentical = array (
+MAX_32Bit, array(MAX_32Bit),
+MIN_32Bit, array(MIN_32Bit),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$invalidIdentical = array (
+MAX_32Bit, array("2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, "2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, "-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+);
+
+
+$failed = false;
+// test for valid values
+for ($i = 0; $i < count($validIdentical); $i +=2) {
+ $typeToTestVal = $validIdentical[$i];
+ $compares = $validIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal === $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' !== '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidIdentical); $i +=2) {
+ $typeToTestVal = $invalidIdentical[$i];
+ $compares = $invalidIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal === $compareVal) {
+ echo "FAILED: '$typeToTestVal' === '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_identical_variation_64bit.phpt b/tests/lang/operators/operator_identical_variation_64bit.phpt
new file mode 100644
index 0000000000..0909c44eab
--- /dev/null
+++ b/tests/lang/operators/operator_identical_variation_64bit.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test === operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validIdentical = array (
+MAX_32Bit, array(MAX_32Bit),
+MIN_32Bit, array(MIN_32Bit),
+MAX_64Bit, array(MAX_64Bit),
+MIN_64Bit, array(MIN_64Bit),
+);
+
+$invalidIdentical = array (
+MAX_32Bit, array("2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, "2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, "-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit - 1, MAX_64Bit + 1),
+MIN_64Bit, array(MIN_64Bit + 1, MIN_64Bit - 1),
+);
+
+
+$failed = false;
+// test for valid values
+for ($i = 0; $i < count($validIdentical); $i +=2) {
+ $typeToTestVal = $validIdentical[$i];
+ $compares = $validIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal === $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' !== '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidIdentical); $i +=2) {
+ $typeToTestVal = $invalidIdentical[$i];
+ $compares = $invalidIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal === $compareVal) {
+ echo "FAILED: '$typeToTestVal' === '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_basic.phpt b/tests/lang/operators/operator_lt_basic.phpt
new file mode 100644
index 0000000000..137adf292c
--- /dev/null
+++ b/tests/lang/operators/operator_lt_basic.phpt
@@ -0,0 +1,62 @@
+--TEST--
+Test < operator : different types
+--FILE--
+<?php
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 677;
+$int2 = -67837;
+$valid_int1 = array("678", "678abc", " 678", "678 ", 678.0, 6.789E2, "+678", +678);
+$valid_int2 = array("-67836", "-67836abc", " -67836", "-67836 ", -67835.0001, -6.78351E4);
+$invalid_int1 = array(676, "676");
+$invalid_int2 = array(-67837, "-67837");
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385.45836", "57385.45836aaa", " 57385.45836", 5.738545836e4);
+$valid_float2 = array("-67345.76566", "-67345.76566aaa", " -67345.76566", -6.734576566E4);
+$invalid_float1 = array(57385.45835, 5.738545835e4);
+$invalid_float2 = array(-67345.76567, -6.734576567E4);
+
+
+$toCompare = array(
+ false, $valid_true, $valid_false,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest < $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest < $compareVal) {
+ echo "FAILED: '$typeToTest' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_or_equal_basic.phpt b/tests/lang/operators/operator_lt_or_equal_basic.phpt
new file mode 100644
index 0000000000..381b813266
--- /dev/null
+++ b/tests/lang/operators/operator_lt_or_equal_basic.phpt
@@ -0,0 +1,64 @@
+--TEST--
+Test <= operator : different types
+--FILE--
+<?php
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 678;
+$int2 = -67836;
+$valid_int1 = array("679", "679abc", " 679", 679.0, 6.79E2, "678", "678abc", " 678", 678.0, 6.78E2, 6.789E2, "+678", +678);
+$valid_int2 = array("-67835", "-67835abc", " -67835", -67835.000, -6.7835E4, "-67836", "-67836abc". " -67836", -67835.0001, -6.78351E4, "-67836", -67835.0001, -6.78351E4);
+$invalid_int1 = array(677, "677");
+$invalid_int2 = array(-67874, "-67837");
+
+$float1 = 57385.45834;
+$float2 = -67345.76568;
+$valid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", 5.738545835e4, "57385.45834", "57385.45834aaa", " 57385.45834", 5.738545834e4);
+$valid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", -6.734576567E4, "-67345.76568", "-67345.76568aaa", " -67345.76568", -6.734576568E4);
+$invalid_float1 = array(57385.45833, 5.738545833e4);
+$invalid_float2 = array(-67345.76569, -6.734576569E4);
+
+$toCompare = array(
+ true, $valid_true, $valid_false,
+ false, array_merge($valid_false, $valid_true), NULL,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest <= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ if ($invalid_compares != NULL) {
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest <= $compareVal) {
+ echo "FAILED: '$typeToTest' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_or_equal_variation.phpt b/tests/lang/operators/operator_lt_or_equal_variation.phpt
new file mode 100644
index 0000000000..8f5f945d7f
--- /dev/null
+++ b/tests/lang/operators/operator_lt_or_equal_variation.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test <= operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validLtOrEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$invalidLtOrEqual = array (
+MAX_32Bit, array("2147483646", 2.1474836460001e9, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit - 1, "-2147483649", -2.1474836480001e9)
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validLtOrEqual); $i +=2) {
+ $typeToTestVal = $validLtOrEqual[$i];
+ $compares = $validLtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal <= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidLtOrEqual); $i +=2) {
+ $typeToTestVal = $invalidLtOrEqual[$i];
+ $compares = $invalidLtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal <= $compareVal) {
+ echo "FAILED: '$typeToTestVal' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt b/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt
new file mode 100644
index 0000000000..03c974fb5d
--- /dev/null
+++ b/tests/lang/operators/operator_lt_or_equal_variation_64bit.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test <= operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validLtOrEqual = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, MAX_32Bit + 1),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$invalidLtOrEqual = array (
+MAX_32Bit, array("2147483646", 2.1474836460001e9, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit - 1, "-2147483649", -2.1474836480001e9)
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validLtOrEqual); $i +=2) {
+ $typeToTestVal = $validLtOrEqual[$i];
+ $compares = $validLtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal <= $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' > '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidLtOrEqual); $i +=2) {
+ $typeToTestVal = $invalidLtOrEqual[$i];
+ $compares = $invalidLtOrEqual[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal <= $compareVal) {
+ echo "FAILED: '$typeToTestVal' <= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_variation.phpt b/tests/lang/operators/operator_lt_variation.phpt
new file mode 100644
index 0000000000..a2a8f6a769
--- /dev/null
+++ b/tests/lang/operators/operator_lt_variation.phpt
@@ -0,0 +1,60 @@
+--TEST--
+Test < operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validLessThan = array (
+2147483646, array(MAX_32Bit, "2147483647", "2147483647.001", 2.147483647e9, 2147483647.9),
+MIN_32Bit, array(MIN_32Bit + 1, "-2147483647", "-2147483646.001", -2.1474836461e9, -2147483646.9),
+);
+
+$invalidLessThan = array (
+MAX_32Bit, array("2147483646", 2.1474836460001e9, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit - 1, "-2147483649", -2.1474836480001e9)
+);
+
+$failed = false;
+// test for equality
+for ($i = 0; $i < count($validLessThan); $i +=2) {
+ $typeToTestVal = $validLessThan[$i];
+ $compares = $validLessThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal < $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidLessThan); $i +=2) {
+ $typeToTestVal = $invalidLessThan[$i];
+ $compares = $invalidLessThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal < $compareVal) {
+ echo "FAILED: '$typeToTestVal' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_lt_variation_64bit.phpt b/tests/lang/operators/operator_lt_variation_64bit.phpt
new file mode 100644
index 0000000000..172ef390d6
--- /dev/null
+++ b/tests/lang/operators/operator_lt_variation_64bit.phpt
@@ -0,0 +1,60 @@
+--TEST--
+Test < operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$validLessThan = array (
+2147483646, array(MAX_32Bit, "2147483647", "2147483647.001", 2.147483647e9, 2147483647.9),
+MIN_32Bit, array(MIN_32Bit + 1, "-2147483647", "-2147483646.001", -2.1474836461e9, -2147483646.9),
+);
+
+$invalidLessThan = array (
+MAX_32Bit, array("2147483646", 2.1474836460001e9, MAX_32Bit - 1),
+MIN_32Bit, array(MIN_32Bit - 1, "-2147483649", -2.1474836480001e9)
+);
+
+$failed = false;
+// test for equality
+for ($i = 0; $i < count($validLessThan); $i +=2) {
+ $typeToTestVal = $validLessThan[$i];
+ $compares = $validLessThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal < $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' >= '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidLessThan); $i +=2) {
+ $typeToTestVal = $invalidLessThan[$i];
+ $compares = $invalidLessThan[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal < $compareVal) {
+ echo "FAILED: '$typeToTestVal' < '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notequals_basic.phpt b/tests/lang/operators/operator_notequals_basic.phpt
new file mode 100644
index 0000000000..059c99df9e
--- /dev/null
+++ b/tests/lang/operators/operator_notequals_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test != operator : different types
+--FILE--
+<?php
+
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array("6 7 9", "6y79", 678);
+$valid_int2 = array("- 67835", "-67,835", "-67 835", "-678y35", -76834);
+$invalid_int1 = array("679", "679abc", " 679", "679 ", 679.0, 6.79E2, "+679", +679);
+$invalid_int2 = array("-67835", "-67835abc", " -67835", "-67835 ", -67835.000, -6.7835E4);
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4);
+$valid_float2 = array("- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4);
+$invalid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", 5.738545835e4);
+$invalid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", -6.734576567E4);
+
+
+$toCompare = array(
+ true, $valid_false, $valid_true,
+ false, $valid_true, $valid_false,
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest != $compareVal && $typeToTest <> $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest != $compareVal || $typeToTest <> $compareVal) {
+ echo "FAILED: '$typeToTest' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notequals_variation.phpt b/tests/lang/operators/operator_notequals_variation.phpt
new file mode 100644
index 0000000000..a7827b4651
--- /dev/null
+++ b/tests/lang/operators/operator_notequals_variation.phpt
@@ -0,0 +1,63 @@
+--TEST--
+Test != operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$invalidNotEquals = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$validNotEquals = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validNotEquals); $i +=2) {
+ $typeToTestVal = $validNotEquals[$i];
+ $compares = $validNotEquals[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal != $compareVal && $typeToTestVal != $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidNotEquals); $i +=2) {
+ $typeToTestVal = $invalidNotEquals[$i];
+ $compares = $invalidNotEquals[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal != $compareVal || $typeToTestVal != $compareVal) {
+ echo "FAILED: '$typeToTestVal' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notequals_variation_64bit.phpt b/tests/lang/operators/operator_notequals_variation_64bit.phpt
new file mode 100644
index 0000000000..ed26b52939
--- /dev/null
+++ b/tests/lang/operators/operator_notequals_variation_64bit.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test == operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$invalidNotEquals = array (
+MAX_32Bit, array(MAX_32Bit, "2147483647", "2147483647.0000000", 2.147483647e9),
+MIN_32Bit, array(MIN_32Bit, "-2147483648", "-2147483648.000", -2.147483648e9),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1),
+);
+
+$validNotEquals = array (
+MAX_32Bit, array("2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit + 1),
+);
+
+
+$failed = false;
+// test valid values
+for ($i = 0; $i < count($validNotEquals); $i +=2) {
+ $typeToTestVal = $validNotEquals[$i];
+ $compares = $validNotEquals[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal != $compareVal && $typeToTestVal <> $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' == '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test invalid values
+for ($i = 0; $i < count($invalidNotEquals); $i +=2) {
+ $typeToTestVal = $invalidNotEquals[$i];
+ $compares = $invalidNotEquals[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal != $compareVal || $typeToTestVal <> $compareVal) {
+ echo "FAILED: '$typeToTestVal' != '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notidentical_basic.phpt b/tests/lang/operators/operator_notidentical_basic.phpt
new file mode 100644
index 0000000000..d433289507
--- /dev/null
+++ b/tests/lang/operators/operator_notidentical_basic.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test !== operator : different types
+--FILE--
+<?php
+
+$valid_true = array(1, "1", "true", 1.0, array(1));
+$valid_false = array(0, "", 0.0, array(), NULL);
+
+$int1 = 679;
+$int2 = -67835;
+$valid_int1 = array("679", "679abc", " 679", "679 ", 679.0, 6.79E2, "+679", "6 7 9", "6y79", 678);
+$valid_int2 = array("-67835", "-67835abc", " -67835", "-67835 ", -67835.000, -6.7835E4, "- 67835", "-67,835", "-67 835", "-678y35", -76834);
+$invalid_int1 = array(679, +679);
+$invalid_int2 = array(-67835);
+
+$float1 = 57385.45835;
+$float2 = -67345.76567;
+$valid_float1 = array("57385.45835", "57385.45835aaa", " 57385.45835", "57385. 45835", "57,385.45835", 57385.45834, 5.738545834e4);
+$valid_float2 = array("-67345.76567", "-67345.76567aaa", " -67345.76567", "- 67345.76567", "-67,345.76567", -67345.76566, -6.734576566E4);
+$invalid_float1 = array(57385.45835, 5.738545835e4);
+$invalid_float2 = array(-67345.76567, -6.734576567E4);
+
+
+$toCompare = array(
+ true, array_merge($valid_true, $valid_false), array(true),
+ false, array_merge($valid_true, $valid_false), array(false),
+ $int1, $valid_int1, $invalid_int1,
+ $int2, $valid_int2, $invalid_int2,
+ $float1, $valid_float1, $invalid_float1,
+ $float2, $valid_float2, $invalid_float2
+);
+
+$failed = false;
+for ($i = 0; $i < count($toCompare); $i +=3) {
+ $typeToTest = $toCompare[$i];
+ $valid_compares = $toCompare[$i + 1];
+ $invalid_compares = $toCompare[$i + 2];
+
+ foreach($valid_compares as $compareVal) {
+ if ($typeToTest !== $compareVal) {
+ // do nothing
+ }
+ else {
+ echo "FAILED: '$typeToTest' === '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+ foreach($invalid_compares as $compareVal) {
+ if ($typeToTest !== $compareVal) {
+ echo "FAILED: '$typeToTest' !== '$compareVal'\n";
+ $failed = true;
+ }
+ }
+
+}
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notidentical_variation.phpt b/tests/lang/operators/operator_notidentical_variation.phpt
new file mode 100644
index 0000000000..9af6f8d6a0
--- /dev/null
+++ b/tests/lang/operators/operator_notidentical_variation.phpt
@@ -0,0 +1,64 @@
+--TEST--
+Test !== operator : max int 32bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$invalidNotIdentical = array (
+MAX_32Bit, array(MAX_32Bit),
+MIN_32Bit, array(MIN_32Bit),
+MAX_64Bit, array(MAX_64Bit, MAX_64Bit + 1, MAX_64Bit - 1),
+MIN_64Bit, array(MIN_64Bit, MIN_64Bit - 1, MIN_64Bit + 1),
+);
+
+$validNotIdentical = array (
+MAX_32Bit, array("2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, "2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, "-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+);
+
+
+$failed = false;
+// test for valid values
+for ($i = 0; $i < count($validNotIdentical); $i +=2) {
+ $typeToTestVal = $validNotIdentical[$i];
+ $compares = $validNotIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal !== $compareVal) {
+ //Do Nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' === '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidNotIdentical); $i +=2) {
+ $typeToTestVal = $invalidNotIdentical[$i];
+ $compares = $invalidNotIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal !== $compareVal) {
+ echo "FAILED: '$typeToTestVal' !== '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/operator_notidentical_variation_64bit.phpt b/tests/lang/operators/operator_notidentical_variation_64bit.phpt
new file mode 100644
index 0000000000..e8f2c7e778
--- /dev/null
+++ b/tests/lang/operators/operator_notidentical_variation_64bit.phpt
@@ -0,0 +1,65 @@
+--TEST--
+Test !== operator : max int 64bit range
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$invalidNotIdentical = array (
+MAX_32Bit, array(MAX_32Bit),
+MIN_32Bit, array(MIN_32Bit),
+MAX_64Bit, array(MAX_64Bit),
+MIN_64Bit, array(MIN_64Bit),
+);
+
+$validNotIdentical = array (
+MAX_32Bit, array("2147483647", "2147483647.0000000", 2.147483647e9, 2147483647.0, "2147483648", 2.1474836470001e9, MAX_32Bit - 1, MAX_32Bit + 1),
+MIN_32Bit, array("-2147483648", "-2147483648.000", -2.147483648e9, -2147483648.0, "-2147483649", -2.1474836480001e9, MIN_32Bit -1, MIN_32Bit + 1),
+MAX_64Bit, array(MAX_64Bit - 1, MAX_64Bit + 1),
+MIN_64Bit, array(MIN_64Bit + 1, MIN_64Bit - 1),
+);
+
+
+$failed = false;
+// test for valid values
+for ($i = 0; $i < count($validNotIdentical); $i +=2) {
+ $typeToTestVal = $validNotIdentical[$i];
+ $compares = $validNotIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal !== $compareVal) {
+ //Do Nothing
+ }
+ else {
+ echo "FAILED: '$typeToTestVal' === '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+// test for invalid values
+for ($i = 0; $i < count($invalidNotIdentical); $i +=2) {
+ $typeToTestVal = $invalidNotIdentical[$i];
+ $compares = $invalidNotIdentical[$i + 1];
+ foreach($compares as $compareVal) {
+ if ($typeToTestVal !== $compareVal) {
+ echo "FAILED: '$typeToTestVal' !== '$compareVal'\n";
+ $failed = true;
+ }
+ }
+}
+
+if ($failed == false) {
+ echo "Test Passed\n";
+}
+
+?>
+===DONE===
+--EXPECT--
+Test Passed
+===DONE=== \ No newline at end of file
diff --git a/tests/lang/operators/postdec_basiclong_64bit.phpt b/tests/lang/operators/postdec_basiclong_64bit.phpt
new file mode 100644
index 0000000000..9875df85ae
--- /dev/null
+++ b/tests/lang/operators/postdec_basiclong_64bit.phpt
@@ -0,0 +1,61 @@
+--TEST--
+Test N-- operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+
+foreach ($longVals as $longVal) {
+ echo "--- testing: $longVal ---\n";
+ $longVal--;
+ var_dump($longVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 ---
+int(9223372036854775806)
+--- testing: -9223372036854775808 ---
+float(-9.2233720368548E+18)
+--- testing: 2147483647 ---
+int(2147483646)
+--- testing: -2147483648 ---
+int(-2147483649)
+--- testing: 9223372034707292160 ---
+int(9223372034707292159)
+--- testing: -9223372034707292160 ---
+int(-9223372034707292161)
+--- testing: 2147483648 ---
+int(2147483647)
+--- testing: -2147483649 ---
+int(-2147483650)
+--- testing: 4294967294 ---
+int(4294967293)
+--- testing: 4294967295 ---
+int(4294967294)
+--- testing: 4294967293 ---
+int(4294967292)
+--- testing: 9223372036854775806 ---
+int(9223372036854775805)
+--- testing: 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775807 ---
+int(-9223372036854775808)
+--- testing: -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+===DONE===
diff --git a/tests/lang/operators/postdec_variationStr.phpt b/tests/lang/operators/postdec_variationStr.phpt
new file mode 100644
index 0000000000..ee5a8cd4b7
--- /dev/null
+++ b/tests/lang/operators/postdec_variationStr.phpt
@@ -0,0 +1,49 @@
+--TEST--
+Test N-- operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ $strVal--;
+ var_dump($strVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+int(-1)
+--- testing: '65' ---
+int(64)
+--- testing: '-44' ---
+int(-45)
+--- testing: '1.2' ---
+float(0.2)
+--- testing: '-7.7' ---
+float(-8.7)
+--- testing: 'abc' ---
+string(3) "abc"
+--- testing: '123abc' ---
+string(6) "123abc"
+--- testing: '123e5' ---
+float(12299999)
+--- testing: '123e5xyz' ---
+string(8) "123e5xyz"
+--- testing: ' 123abc' ---
+string(7) " 123abc"
+--- testing: '123 abc' ---
+string(7) "123 abc"
+--- testing: '123abc ' ---
+string(7) "123abc "
+--- testing: '3.4a' ---
+string(4) "3.4a"
+--- testing: 'a5.9' ---
+string(4) "a5.9"
+===DONE===
diff --git a/tests/lang/operators/postinc_basiclong_64bit.phpt b/tests/lang/operators/postinc_basiclong_64bit.phpt
new file mode 100644
index 0000000000..494259acd8
--- /dev/null
+++ b/tests/lang/operators/postinc_basiclong_64bit.phpt
@@ -0,0 +1,61 @@
+--TEST--
+Test N++ operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+
+foreach ($longVals as $longVal) {
+ echo "--- testing: $longVal ---\n";
+ $longVal++;
+ var_dump($longVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775808 ---
+int(-9223372036854775807)
+--- testing: 2147483647 ---
+int(2147483648)
+--- testing: -2147483648 ---
+int(-2147483647)
+--- testing: 9223372034707292160 ---
+int(9223372034707292161)
+--- testing: -9223372034707292160 ---
+int(-9223372034707292159)
+--- testing: 2147483648 ---
+int(2147483649)
+--- testing: -2147483649 ---
+int(-2147483648)
+--- testing: 4294967294 ---
+int(4294967295)
+--- testing: 4294967295 ---
+int(4294967296)
+--- testing: 4294967293 ---
+int(4294967294)
+--- testing: 9223372036854775806 ---
+int(9223372036854775807)
+--- testing: 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775807 ---
+int(-9223372036854775806)
+--- testing: -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+===DONE===
diff --git a/tests/lang/operators/postinc_variationStr.phpt b/tests/lang/operators/postinc_variationStr.phpt
new file mode 100644
index 0000000000..6fbe804319
--- /dev/null
+++ b/tests/lang/operators/postinc_variationStr.phpt
@@ -0,0 +1,49 @@
+--TEST--
+Test N++ operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ $strVal++;
+ var_dump($strVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+int(1)
+--- testing: '65' ---
+int(66)
+--- testing: '-44' ---
+int(-43)
+--- testing: '1.2' ---
+float(2.2)
+--- testing: '-7.7' ---
+float(-6.7)
+--- testing: 'abc' ---
+string(3) "abd"
+--- testing: '123abc' ---
+string(6) "123abd"
+--- testing: '123e5' ---
+float(12300001)
+--- testing: '123e5xyz' ---
+string(8) "123e5xza"
+--- testing: ' 123abc' ---
+string(7) " 123abd"
+--- testing: '123 abc' ---
+string(7) "123 abd"
+--- testing: '123abc ' ---
+string(7) "123abc "
+--- testing: '3.4a' ---
+string(4) "3.4b"
+--- testing: 'a5.9' ---
+string(4) "a5.0"
+===DONE===
diff --git a/tests/lang/operators/predec_basiclong_64bit.phpt b/tests/lang/operators/predec_basiclong_64bit.phpt
new file mode 100644
index 0000000000..c1b15fdf34
--- /dev/null
+++ b/tests/lang/operators/predec_basiclong_64bit.phpt
@@ -0,0 +1,60 @@
+--TEST--
+Test --N operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+
+foreach ($longVals as $longVal) {
+ echo "--- testing: $longVal ---\n";
+ var_dump(--$longVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 ---
+int(9223372036854775806)
+--- testing: -9223372036854775808 ---
+float(-9.2233720368548E+18)
+--- testing: 2147483647 ---
+int(2147483646)
+--- testing: -2147483648 ---
+int(-2147483649)
+--- testing: 9223372034707292160 ---
+int(9223372034707292159)
+--- testing: -9223372034707292160 ---
+int(-9223372034707292161)
+--- testing: 2147483648 ---
+int(2147483647)
+--- testing: -2147483649 ---
+int(-2147483650)
+--- testing: 4294967294 ---
+int(4294967293)
+--- testing: 4294967295 ---
+int(4294967294)
+--- testing: 4294967293 ---
+int(4294967292)
+--- testing: 9223372036854775806 ---
+int(9223372036854775805)
+--- testing: 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775807 ---
+int(-9223372036854775808)
+--- testing: -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+===DONE===
diff --git a/tests/lang/operators/predec_variationStr.phpt b/tests/lang/operators/predec_variationStr.phpt
new file mode 100644
index 0000000000..c7fb5744a0
--- /dev/null
+++ b/tests/lang/operators/predec_variationStr.phpt
@@ -0,0 +1,48 @@
+--TEST--
+Test --N operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ var_dump(--$strVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+int(-1)
+--- testing: '65' ---
+int(64)
+--- testing: '-44' ---
+int(-45)
+--- testing: '1.2' ---
+float(0.2)
+--- testing: '-7.7' ---
+float(-8.7)
+--- testing: 'abc' ---
+string(3) "abc"
+--- testing: '123abc' ---
+string(6) "123abc"
+--- testing: '123e5' ---
+float(12299999)
+--- testing: '123e5xyz' ---
+string(8) "123e5xyz"
+--- testing: ' 123abc' ---
+string(7) " 123abc"
+--- testing: '123 abc' ---
+string(7) "123 abc"
+--- testing: '123abc ' ---
+string(7) "123abc "
+--- testing: '3.4a' ---
+string(4) "3.4a"
+--- testing: 'a5.9' ---
+string(4) "a5.9"
+===DONE===
diff --git a/tests/lang/operators/preinc_basiclong_64bit.phpt b/tests/lang/operators/preinc_basiclong_64bit.phpt
new file mode 100644
index 0000000000..599aa4e001
--- /dev/null
+++ b/tests/lang/operators/preinc_basiclong_64bit.phpt
@@ -0,0 +1,60 @@
+--TEST--
+Test ++N operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+
+foreach ($longVals as $longVal) {
+ echo "--- testing: $longVal ---\n";
+ var_dump(++$longVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775808 ---
+int(-9223372036854775807)
+--- testing: 2147483647 ---
+int(2147483648)
+--- testing: -2147483648 ---
+int(-2147483647)
+--- testing: 9223372034707292160 ---
+int(9223372034707292161)
+--- testing: -9223372034707292160 ---
+int(-9223372034707292159)
+--- testing: 2147483648 ---
+int(2147483649)
+--- testing: -2147483649 ---
+int(-2147483648)
+--- testing: 4294967294 ---
+int(4294967295)
+--- testing: 4294967295 ---
+int(4294967296)
+--- testing: 4294967293 ---
+int(4294967294)
+--- testing: 9223372036854775806 ---
+int(9223372036854775807)
+--- testing: 9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -9223372036854775807 ---
+int(-9223372036854775806)
+--- testing: -9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+===DONE===
diff --git a/tests/lang/operators/preinc_variationStr.phpt b/tests/lang/operators/preinc_variationStr.phpt
new file mode 100644
index 0000000000..010a237034
--- /dev/null
+++ b/tests/lang/operators/preinc_variationStr.phpt
@@ -0,0 +1,48 @@
+--TEST--
+Test ++N operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+
+foreach ($strVals as $strVal) {
+ echo "--- testing: '$strVal' ---\n";
+ var_dump(++$strVal);
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' ---
+int(1)
+--- testing: '65' ---
+int(66)
+--- testing: '-44' ---
+int(-43)
+--- testing: '1.2' ---
+float(2.2)
+--- testing: '-7.7' ---
+float(-6.7)
+--- testing: 'abc' ---
+string(3) "abd"
+--- testing: '123abc' ---
+string(6) "123abd"
+--- testing: '123e5' ---
+float(12300001)
+--- testing: '123e5xyz' ---
+string(8) "123e5xza"
+--- testing: ' 123abc' ---
+string(7) " 123abd"
+--- testing: '123 abc' ---
+string(7) "123 abd"
+--- testing: '123abc ' ---
+string(7) "123abc "
+--- testing: '3.4a' ---
+string(4) "3.4b"
+--- testing: 'a5.9' ---
+string(4) "a5.0"
+===DONE===
diff --git a/tests/lang/operators/subtract_basiclong_64bit.phpt b/tests/lang/operators/subtract_basiclong_64bit.phpt
new file mode 100644
index 0000000000..f52b951442
--- /dev/null
+++ b/tests/lang/operators/subtract_basiclong_64bit.phpt
@@ -0,0 +1,582 @@
+--TEST--
+Test - operator : 64bit long tests
+--SKIPIF--
+<?php
+if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only");
+?>
+--FILE--
+<?php
+
+define("MAX_64Bit", 9223372036854775807);
+define("MAX_32Bit", 2147483647);
+define("MIN_64Bit", -9223372036854775807 - 1);
+define("MIN_32Bit", -2147483647 - 1);
+
+$longVals = array(
+ MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
+ MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
+ MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
+);
+
+$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
+
+error_reporting(E_ERROR);
+
+foreach ($longVals as $longVal) {
+ foreach($otherVals as $otherVal) {
+ echo "--- testing: $longVal - $otherVal ---\n";
+ var_dump($longVal-$otherVal);
+ }
+}
+
+foreach ($otherVals as $otherVal) {
+ foreach($longVals as $longVal) {
+ echo "--- testing: $otherVal - $longVal ---\n";
+ var_dump($otherVal-$longVal);
+ }
+}
+
+?>
+===DONE===
+--EXPECT--
+--- testing: 9223372036854775807 - 0 ---
+int(9223372036854775807)
+--- testing: 9223372036854775807 - 1 ---
+int(9223372036854775806)
+--- testing: 9223372036854775807 - -1 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 - 7 ---
+int(9223372036854775800)
+--- testing: 9223372036854775807 - 9 ---
+int(9223372036854775798)
+--- testing: 9223372036854775807 - 65 ---
+int(9223372036854775742)
+--- testing: 9223372036854775807 - -44 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775807 - 2147483647 ---
+int(9223372034707292160)
+--- testing: 9223372036854775807 - 9223372036854775807 ---
+int(0)
+--- testing: -9223372036854775808 - 0 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775808 - 1 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 - -1 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775808 - 7 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 - 9 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 - 65 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775808 - -44 ---
+int(-9223372036854775764)
+--- testing: -9223372036854775808 - 2147483647 ---
+float(-9.2233720390023E+18)
+--- testing: -9223372036854775808 - 9223372036854775807 ---
+float(-1.844674407371E+19)
+--- testing: 2147483647 - 0 ---
+int(2147483647)
+--- testing: 2147483647 - 1 ---
+int(2147483646)
+--- testing: 2147483647 - -1 ---
+int(2147483648)
+--- testing: 2147483647 - 7 ---
+int(2147483640)
+--- testing: 2147483647 - 9 ---
+int(2147483638)
+--- testing: 2147483647 - 65 ---
+int(2147483582)
+--- testing: 2147483647 - -44 ---
+int(2147483691)
+--- testing: 2147483647 - 2147483647 ---
+int(0)
+--- testing: 2147483647 - 9223372036854775807 ---
+int(-9223372034707292160)
+--- testing: -2147483648 - 0 ---
+int(-2147483648)
+--- testing: -2147483648 - 1 ---
+int(-2147483649)
+--- testing: -2147483648 - -1 ---
+int(-2147483647)
+--- testing: -2147483648 - 7 ---
+int(-2147483655)
+--- testing: -2147483648 - 9 ---
+int(-2147483657)
+--- testing: -2147483648 - 65 ---
+int(-2147483713)
+--- testing: -2147483648 - -44 ---
+int(-2147483604)
+--- testing: -2147483648 - 2147483647 ---
+int(-4294967295)
+--- testing: -2147483648 - 9223372036854775807 ---
+float(-9.2233720390023E+18)
+--- testing: 9223372034707292160 - 0 ---
+int(9223372034707292160)
+--- testing: 9223372034707292160 - 1 ---
+int(9223372034707292159)
+--- testing: 9223372034707292160 - -1 ---
+int(9223372034707292161)
+--- testing: 9223372034707292160 - 7 ---
+int(9223372034707292153)
+--- testing: 9223372034707292160 - 9 ---
+int(9223372034707292151)
+--- testing: 9223372034707292160 - 65 ---
+int(9223372034707292095)
+--- testing: 9223372034707292160 - -44 ---
+int(9223372034707292204)
+--- testing: 9223372034707292160 - 2147483647 ---
+int(9223372032559808513)
+--- testing: 9223372034707292160 - 9223372036854775807 ---
+int(-2147483647)
+--- testing: -9223372034707292160 - 0 ---
+int(-9223372034707292160)
+--- testing: -9223372034707292160 - 1 ---
+int(-9223372034707292161)
+--- testing: -9223372034707292160 - -1 ---
+int(-9223372034707292159)
+--- testing: -9223372034707292160 - 7 ---
+int(-9223372034707292167)
+--- testing: -9223372034707292160 - 9 ---
+int(-9223372034707292169)
+--- testing: -9223372034707292160 - 65 ---
+int(-9223372034707292225)
+--- testing: -9223372034707292160 - -44 ---
+int(-9223372034707292116)
+--- testing: -9223372034707292160 - 2147483647 ---
+int(-9223372036854775807)
+--- testing: -9223372034707292160 - 9223372036854775807 ---
+float(-1.8446744071562E+19)
+--- testing: 2147483648 - 0 ---
+int(2147483648)
+--- testing: 2147483648 - 1 ---
+int(2147483647)
+--- testing: 2147483648 - -1 ---
+int(2147483649)
+--- testing: 2147483648 - 7 ---
+int(2147483641)
+--- testing: 2147483648 - 9 ---
+int(2147483639)
+--- testing: 2147483648 - 65 ---
+int(2147483583)
+--- testing: 2147483648 - -44 ---
+int(2147483692)
+--- testing: 2147483648 - 2147483647 ---
+int(1)
+--- testing: 2147483648 - 9223372036854775807 ---
+int(-9223372034707292159)
+--- testing: -2147483649 - 0 ---
+int(-2147483649)
+--- testing: -2147483649 - 1 ---
+int(-2147483650)
+--- testing: -2147483649 - -1 ---
+int(-2147483648)
+--- testing: -2147483649 - 7 ---
+int(-2147483656)
+--- testing: -2147483649 - 9 ---
+int(-2147483658)
+--- testing: -2147483649 - 65 ---
+int(-2147483714)
+--- testing: -2147483649 - -44 ---
+int(-2147483605)
+--- testing: -2147483649 - 2147483647 ---
+int(-4294967296)
+--- testing: -2147483649 - 9223372036854775807 ---
+float(-9.2233720390023E+18)
+--- testing: 4294967294 - 0 ---
+int(4294967294)
+--- testing: 4294967294 - 1 ---
+int(4294967293)
+--- testing: 4294967294 - -1 ---
+int(4294967295)
+--- testing: 4294967294 - 7 ---
+int(4294967287)
+--- testing: 4294967294 - 9 ---
+int(4294967285)
+--- testing: 4294967294 - 65 ---
+int(4294967229)
+--- testing: 4294967294 - -44 ---
+int(4294967338)
+--- testing: 4294967294 - 2147483647 ---
+int(2147483647)
+--- testing: 4294967294 - 9223372036854775807 ---
+int(-9223372032559808513)
+--- testing: 4294967295 - 0 ---
+int(4294967295)
+--- testing: 4294967295 - 1 ---
+int(4294967294)
+--- testing: 4294967295 - -1 ---
+int(4294967296)
+--- testing: 4294967295 - 7 ---
+int(4294967288)
+--- testing: 4294967295 - 9 ---
+int(4294967286)
+--- testing: 4294967295 - 65 ---
+int(4294967230)
+--- testing: 4294967295 - -44 ---
+int(4294967339)
+--- testing: 4294967295 - 2147483647 ---
+int(2147483648)
+--- testing: 4294967295 - 9223372036854775807 ---
+int(-9223372032559808512)
+--- testing: 4294967293 - 0 ---
+int(4294967293)
+--- testing: 4294967293 - 1 ---
+int(4294967292)
+--- testing: 4294967293 - -1 ---
+int(4294967294)
+--- testing: 4294967293 - 7 ---
+int(4294967286)
+--- testing: 4294967293 - 9 ---
+int(4294967284)
+--- testing: 4294967293 - 65 ---
+int(4294967228)
+--- testing: 4294967293 - -44 ---
+int(4294967337)
+--- testing: 4294967293 - 2147483647 ---
+int(2147483646)
+--- testing: 4294967293 - 9223372036854775807 ---
+int(-9223372032559808514)
+--- testing: 9223372036854775806 - 0 ---
+int(9223372036854775806)
+--- testing: 9223372036854775806 - 1 ---
+int(9223372036854775805)
+--- testing: 9223372036854775806 - -1 ---
+int(9223372036854775807)
+--- testing: 9223372036854775806 - 7 ---
+int(9223372036854775799)
+--- testing: 9223372036854775806 - 9 ---
+int(9223372036854775797)
+--- testing: 9223372036854775806 - 65 ---
+int(9223372036854775741)
+--- testing: 9223372036854775806 - -44 ---
+float(9.2233720368548E+18)
+--- testing: 9223372036854775806 - 2147483647 ---
+int(9223372034707292159)
+--- testing: 9223372036854775806 - 9223372036854775807 ---
+int(-1)
+--- testing: 9.2233720368548E+18 - 0 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - 1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - -1 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - 7 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - 9 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - 65 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - -44 ---
+float(9.2233720368548E+18)
+--- testing: 9.2233720368548E+18 - 2147483647 ---
+float(9.2233720347073E+18)
+--- testing: 9.2233720368548E+18 - 9223372036854775807 ---
+float(0)
+--- testing: -9223372036854775807 - 0 ---
+int(-9223372036854775807)
+--- testing: -9223372036854775807 - 1 ---
+int(-9223372036854775808)
+--- testing: -9223372036854775807 - -1 ---
+int(-9223372036854775806)
+--- testing: -9223372036854775807 - 7 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775807 - 9 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775807 - 65 ---
+float(-9.2233720368548E+18)
+--- testing: -9223372036854775807 - -44 ---
+int(-9223372036854775763)
+--- testing: -9223372036854775807 - 2147483647 ---
+float(-9.2233720390023E+18)
+--- testing: -9223372036854775807 - 9223372036854775807 ---
+float(-1.844674407371E+19)
+--- testing: -9.2233720368548E+18 - 0 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - 1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - -1 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - 7 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - 9 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - 65 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - -44 ---
+float(-9.2233720368548E+18)
+--- testing: -9.2233720368548E+18 - 2147483647 ---
+float(-9.2233720390023E+18)
+--- testing: -9.2233720368548E+18 - 9223372036854775807 ---
+float(-1.844674407371E+19)
+--- testing: 0 - 9223372036854775807 ---
+int(-9223372036854775807)
+--- testing: 0 - -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 0 - 2147483647 ---
+int(-2147483647)
+--- testing: 0 - -2147483648 ---
+int(2147483648)
+--- testing: 0 - 9223372034707292160 ---
+int(-9223372034707292160)
+--- testing: 0 - -9223372034707292160 ---
+int(9223372034707292160)
+--- testing: 0 - 2147483648 ---
+int(-2147483648)
+--- testing: 0 - -2147483649 ---
+int(2147483649)
+--- testing: 0 - 4294967294 ---
+int(-4294967294)
+--- testing: 0 - 4294967295 ---
+int(-4294967295)
+--- testing: 0 - 4294967293 ---
+int(-4294967293)
+--- testing: 0 - 9223372036854775806 ---
+int(-9223372036854775806)
+--- testing: 0 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 0 - -9223372036854775807 ---
+int(9223372036854775807)
+--- testing: 0 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 1 - 9223372036854775807 ---
+int(-9223372036854775806)
+--- testing: 1 - -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 1 - 2147483647 ---
+int(-2147483646)
+--- testing: 1 - -2147483648 ---
+int(2147483649)
+--- testing: 1 - 9223372034707292160 ---
+int(-9223372034707292159)
+--- testing: 1 - -9223372034707292160 ---
+int(9223372034707292161)
+--- testing: 1 - 2147483648 ---
+int(-2147483647)
+--- testing: 1 - -2147483649 ---
+int(2147483650)
+--- testing: 1 - 4294967294 ---
+int(-4294967293)
+--- testing: 1 - 4294967295 ---
+int(-4294967294)
+--- testing: 1 - 4294967293 ---
+int(-4294967292)
+--- testing: 1 - 9223372036854775806 ---
+int(-9223372036854775805)
+--- testing: 1 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 1 - -9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 1 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -1 - 9223372036854775807 ---
+int(-9223372036854775808)
+--- testing: -1 - -9223372036854775808 ---
+int(9223372036854775807)
+--- testing: -1 - 2147483647 ---
+int(-2147483648)
+--- testing: -1 - -2147483648 ---
+int(2147483647)
+--- testing: -1 - 9223372034707292160 ---
+int(-9223372034707292161)
+--- testing: -1 - -9223372034707292160 ---
+int(9223372034707292159)
+--- testing: -1 - 2147483648 ---
+int(-2147483649)
+--- testing: -1 - -2147483649 ---
+int(2147483648)
+--- testing: -1 - 4294967294 ---
+int(-4294967295)
+--- testing: -1 - 4294967295 ---
+int(-4294967296)
+--- testing: -1 - 4294967293 ---
+int(-4294967294)
+--- testing: -1 - 9223372036854775806 ---
+int(-9223372036854775807)
+--- testing: -1 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -1 - -9223372036854775807 ---
+int(9223372036854775806)
+--- testing: -1 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 7 - 9223372036854775807 ---
+int(-9223372036854775800)
+--- testing: 7 - -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 7 - 2147483647 ---
+int(-2147483640)
+--- testing: 7 - -2147483648 ---
+int(2147483655)
+--- testing: 7 - 9223372034707292160 ---
+int(-9223372034707292153)
+--- testing: 7 - -9223372034707292160 ---
+int(9223372034707292167)
+--- testing: 7 - 2147483648 ---
+int(-2147483641)
+--- testing: 7 - -2147483649 ---
+int(2147483656)
+--- testing: 7 - 4294967294 ---
+int(-4294967287)
+--- testing: 7 - 4294967295 ---
+int(-4294967288)
+--- testing: 7 - 4294967293 ---
+int(-4294967286)
+--- testing: 7 - 9223372036854775806 ---
+int(-9223372036854775799)
+--- testing: 7 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 7 - -9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 7 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 9 - 9223372036854775807 ---
+int(-9223372036854775798)
+--- testing: 9 - -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 9 - 2147483647 ---
+int(-2147483638)
+--- testing: 9 - -2147483648 ---
+int(2147483657)
+--- testing: 9 - 9223372034707292160 ---
+int(-9223372034707292151)
+--- testing: 9 - -9223372034707292160 ---
+int(9223372034707292169)
+--- testing: 9 - 2147483648 ---
+int(-2147483639)
+--- testing: 9 - -2147483649 ---
+int(2147483658)
+--- testing: 9 - 4294967294 ---
+int(-4294967285)
+--- testing: 9 - 4294967295 ---
+int(-4294967286)
+--- testing: 9 - 4294967293 ---
+int(-4294967284)
+--- testing: 9 - 9223372036854775806 ---
+int(-9223372036854775797)
+--- testing: 9 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 9 - -9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 9 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 65 - 9223372036854775807 ---
+int(-9223372036854775742)
+--- testing: 65 - -9223372036854775808 ---
+float(9.2233720368548E+18)
+--- testing: 65 - 2147483647 ---
+int(-2147483582)
+--- testing: 65 - -2147483648 ---
+int(2147483713)
+--- testing: 65 - 9223372034707292160 ---
+int(-9223372034707292095)
+--- testing: 65 - -9223372034707292160 ---
+int(9223372034707292225)
+--- testing: 65 - 2147483648 ---
+int(-2147483583)
+--- testing: 65 - -2147483649 ---
+int(2147483714)
+--- testing: 65 - 4294967294 ---
+int(-4294967229)
+--- testing: 65 - 4294967295 ---
+int(-4294967230)
+--- testing: 65 - 4294967293 ---
+int(-4294967228)
+--- testing: 65 - 9223372036854775806 ---
+int(-9223372036854775741)
+--- testing: 65 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: 65 - -9223372036854775807 ---
+float(9.2233720368548E+18)
+--- testing: 65 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: -44 - 9223372036854775807 ---
+float(-9.2233720368548E+18)
+--- testing: -44 - -9223372036854775808 ---
+int(9223372036854775764)
+--- testing: -44 - 2147483647 ---
+int(-2147483691)
+--- testing: -44 - -2147483648 ---
+int(2147483604)
+--- testing: -44 - 9223372034707292160 ---
+int(-9223372034707292204)
+--- testing: -44 - -9223372034707292160 ---
+int(9223372034707292116)
+--- testing: -44 - 2147483648 ---
+int(-2147483692)
+--- testing: -44 - -2147483649 ---
+int(2147483605)
+--- testing: -44 - 4294967294 ---
+int(-4294967338)
+--- testing: -44 - 4294967295 ---
+int(-4294967339)
+--- testing: -44 - 4294967293 ---
+int(-4294967337)
+--- testing: -44 - 9223372036854775806 ---
+float(-9.2233720368548E+18)
+--- testing: -44 - 9.2233720368548E+18 ---
+float(-9.2233720368548E+18)
+--- testing: -44 - -9223372036854775807 ---
+int(9223372036854775763)
+--- testing: -44 - -9.2233720368548E+18 ---
+float(9.2233720368548E+18)
+--- testing: 2147483647 - 9223372036854775807 ---
+int(-9223372034707292160)
+--- testing: 2147483647 - -9223372036854775808 ---
+float(9.2233720390023E+18)
+--- testing: 2147483647 - 2147483647 ---
+int(0)
+--- testing: 2147483647 - -2147483648 ---
+int(4294967295)
+--- testing: 2147483647 - 9223372034707292160 ---
+int(-9223372032559808513)
+--- testing: 2147483647 - -9223372034707292160 ---
+int(9223372036854775807)
+--- testing: 2147483647 - 2147483648 ---
+int(-1)
+--- testing: 2147483647 - -2147483649 ---
+int(4294967296)
+--- testing: 2147483647 - 4294967294 ---
+int(-2147483647)
+--- testing: 2147483647 - 4294967295 ---
+int(-2147483648)
+--- testing: 2147483647 - 4294967293 ---
+int(-2147483646)
+--- testing: 2147483647 - 9223372036854775806 ---
+int(-9223372034707292159)
+--- testing: 2147483647 - 9.2233720368548E+18 ---
+float(-9.2233720347073E+18)
+--- testing: 2147483647 - -9223372036854775807 ---
+float(9.2233720390023E+18)
+--- testing: 2147483647 - -9.2233720368548E+18 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 - 9223372036854775807 ---
+int(0)
+--- testing: 9223372036854775807 - -9223372036854775808 ---
+float(1.844674407371E+19)
+--- testing: 9223372036854775807 - 2147483647 ---
+int(9223372034707292160)
+--- testing: 9223372036854775807 - -2147483648 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 - 9223372034707292160 ---
+int(2147483647)
+--- testing: 9223372036854775807 - -9223372034707292160 ---
+float(1.8446744071562E+19)
+--- testing: 9223372036854775807 - 2147483648 ---
+int(9223372034707292159)
+--- testing: 9223372036854775807 - -2147483649 ---
+float(9.2233720390023E+18)
+--- testing: 9223372036854775807 - 4294967294 ---
+int(9223372032559808513)
+--- testing: 9223372036854775807 - 4294967295 ---
+int(9223372032559808512)
+--- testing: 9223372036854775807 - 4294967293 ---
+int(9223372032559808514)
+--- testing: 9223372036854775807 - 9223372036854775806 ---
+int(1)
+--- testing: 9223372036854775807 - 9.2233720368548E+18 ---
+float(0)
+--- testing: 9223372036854775807 - -9223372036854775807 ---
+float(1.844674407371E+19)
+--- testing: 9223372036854775807 - -9.2233720368548E+18 ---
+float(1.844674407371E+19)
+===DONE===
diff --git a/tests/lang/operators/subtract_variationStr.phpt b/tests/lang/operators/subtract_variationStr.phpt
new file mode 100644
index 0000000000..5b5bae2e35
--- /dev/null
+++ b/tests/lang/operators/subtract_variationStr.phpt
@@ -0,0 +1,416 @@
+--TEST--
+Test - operator : various numbers as strings
+--FILE--
+<?php
+
+$strVals = array(
+ "0","65","-44", "1.2", "-7.7", "abc", "123abc", "123e5", "123e5xyz", " 123abc", "123 abc", "123abc ", "3.4a",
+ "a5.9"
+);
+
+error_reporting(E_ERROR);
+
+foreach ($strVals as $strVal) {
+ foreach($strVals as $otherVal) {
+ echo "--- testing: '$strVal' - '$otherVal' ---\n";
+ var_dump($strVal-$otherVal);
+ }
+}
+
+
+?>
+===DONE===
+--EXPECT--
+--- testing: '0' - '0' ---
+int(0)
+--- testing: '0' - '65' ---
+int(-65)
+--- testing: '0' - '-44' ---
+int(44)
+--- testing: '0' - '1.2' ---
+float(-1.2)
+--- testing: '0' - '-7.7' ---
+float(7.7)
+--- testing: '0' - 'abc' ---
+int(0)
+--- testing: '0' - '123abc' ---
+int(-123)
+--- testing: '0' - '123e5' ---
+float(-12300000)
+--- testing: '0' - '123e5xyz' ---
+float(-12300000)
+--- testing: '0' - ' 123abc' ---
+int(-123)
+--- testing: '0' - '123 abc' ---
+int(-123)
+--- testing: '0' - '123abc ' ---
+int(-123)
+--- testing: '0' - '3.4a' ---
+float(-3.4)
+--- testing: '0' - 'a5.9' ---
+int(0)
+--- testing: '65' - '0' ---
+int(65)
+--- testing: '65' - '65' ---
+int(0)
+--- testing: '65' - '-44' ---
+int(109)
+--- testing: '65' - '1.2' ---
+float(63.8)
+--- testing: '65' - '-7.7' ---
+float(72.7)
+--- testing: '65' - 'abc' ---
+int(65)
+--- testing: '65' - '123abc' ---
+int(-58)
+--- testing: '65' - '123e5' ---
+float(-12299935)
+--- testing: '65' - '123e5xyz' ---
+float(-12299935)
+--- testing: '65' - ' 123abc' ---
+int(-58)
+--- testing: '65' - '123 abc' ---
+int(-58)
+--- testing: '65' - '123abc ' ---
+int(-58)
+--- testing: '65' - '3.4a' ---
+float(61.6)
+--- testing: '65' - 'a5.9' ---
+int(65)
+--- testing: '-44' - '0' ---
+int(-44)
+--- testing: '-44' - '65' ---
+int(-109)
+--- testing: '-44' - '-44' ---
+int(0)
+--- testing: '-44' - '1.2' ---
+float(-45.2)
+--- testing: '-44' - '-7.7' ---
+float(-36.3)
+--- testing: '-44' - 'abc' ---
+int(-44)
+--- testing: '-44' - '123abc' ---
+int(-167)
+--- testing: '-44' - '123e5' ---
+float(-12300044)
+--- testing: '-44' - '123e5xyz' ---
+float(-12300044)
+--- testing: '-44' - ' 123abc' ---
+int(-167)
+--- testing: '-44' - '123 abc' ---
+int(-167)
+--- testing: '-44' - '123abc ' ---
+int(-167)
+--- testing: '-44' - '3.4a' ---
+float(-47.4)
+--- testing: '-44' - 'a5.9' ---
+int(-44)
+--- testing: '1.2' - '0' ---
+float(1.2)
+--- testing: '1.2' - '65' ---
+float(-63.8)
+--- testing: '1.2' - '-44' ---
+float(45.2)
+--- testing: '1.2' - '1.2' ---
+float(0)
+--- testing: '1.2' - '-7.7' ---
+float(8.9)
+--- testing: '1.2' - 'abc' ---
+float(1.2)
+--- testing: '1.2' - '123abc' ---
+float(-121.8)
+--- testing: '1.2' - '123e5' ---
+float(-12299998.8)
+--- testing: '1.2' - '123e5xyz' ---
+float(-12299998.8)
+--- testing: '1.2' - ' 123abc' ---
+float(-121.8)
+--- testing: '1.2' - '123 abc' ---
+float(-121.8)
+--- testing: '1.2' - '123abc ' ---
+float(-121.8)
+--- testing: '1.2' - '3.4a' ---
+float(-2.2)
+--- testing: '1.2' - 'a5.9' ---
+float(1.2)
+--- testing: '-7.7' - '0' ---
+float(-7.7)
+--- testing: '-7.7' - '65' ---
+float(-72.7)
+--- testing: '-7.7' - '-44' ---
+float(36.3)
+--- testing: '-7.7' - '1.2' ---
+float(-8.9)
+--- testing: '-7.7' - '-7.7' ---
+float(0)
+--- testing: '-7.7' - 'abc' ---
+float(-7.7)
+--- testing: '-7.7' - '123abc' ---
+float(-130.7)
+--- testing: '-7.7' - '123e5' ---
+float(-12300007.7)
+--- testing: '-7.7' - '123e5xyz' ---
+float(-12300007.7)
+--- testing: '-7.7' - ' 123abc' ---
+float(-130.7)
+--- testing: '-7.7' - '123 abc' ---
+float(-130.7)
+--- testing: '-7.7' - '123abc ' ---
+float(-130.7)
+--- testing: '-7.7' - '3.4a' ---
+float(-11.1)
+--- testing: '-7.7' - 'a5.9' ---
+float(-7.7)
+--- testing: 'abc' - '0' ---
+int(0)
+--- testing: 'abc' - '65' ---
+int(-65)
+--- testing: 'abc' - '-44' ---
+int(44)
+--- testing: 'abc' - '1.2' ---
+float(-1.2)
+--- testing: 'abc' - '-7.7' ---
+float(7.7)
+--- testing: 'abc' - 'abc' ---
+int(0)
+--- testing: 'abc' - '123abc' ---
+int(-123)
+--- testing: 'abc' - '123e5' ---
+float(-12300000)
+--- testing: 'abc' - '123e5xyz' ---
+float(-12300000)
+--- testing: 'abc' - ' 123abc' ---
+int(-123)
+--- testing: 'abc' - '123 abc' ---
+int(-123)
+--- testing: 'abc' - '123abc ' ---
+int(-123)
+--- testing: 'abc' - '3.4a' ---
+float(-3.4)
+--- testing: 'abc' - 'a5.9' ---
+int(0)
+--- testing: '123abc' - '0' ---
+int(123)
+--- testing: '123abc' - '65' ---
+int(58)
+--- testing: '123abc' - '-44' ---
+int(167)
+--- testing: '123abc' - '1.2' ---
+float(121.8)
+--- testing: '123abc' - '-7.7' ---
+float(130.7)
+--- testing: '123abc' - 'abc' ---
+int(123)
+--- testing: '123abc' - '123abc' ---
+int(0)
+--- testing: '123abc' - '123e5' ---
+float(-12299877)
+--- testing: '123abc' - '123e5xyz' ---
+float(-12299877)
+--- testing: '123abc' - ' 123abc' ---
+int(0)
+--- testing: '123abc' - '123 abc' ---
+int(0)
+--- testing: '123abc' - '123abc ' ---
+int(0)
+--- testing: '123abc' - '3.4a' ---
+float(119.6)
+--- testing: '123abc' - 'a5.9' ---
+int(123)
+--- testing: '123e5' - '0' ---
+float(12300000)
+--- testing: '123e5' - '65' ---
+float(12299935)
+--- testing: '123e5' - '-44' ---
+float(12300044)
+--- testing: '123e5' - '1.2' ---
+float(12299998.8)
+--- testing: '123e5' - '-7.7' ---
+float(12300007.7)
+--- testing: '123e5' - 'abc' ---
+float(12300000)
+--- testing: '123e5' - '123abc' ---
+float(12299877)
+--- testing: '123e5' - '123e5' ---
+float(0)
+--- testing: '123e5' - '123e5xyz' ---
+float(0)
+--- testing: '123e5' - ' 123abc' ---
+float(12299877)
+--- testing: '123e5' - '123 abc' ---
+float(12299877)
+--- testing: '123e5' - '123abc ' ---
+float(12299877)
+--- testing: '123e5' - '3.4a' ---
+float(12299996.6)
+--- testing: '123e5' - 'a5.9' ---
+float(12300000)
+--- testing: '123e5xyz' - '0' ---
+float(12300000)
+--- testing: '123e5xyz' - '65' ---
+float(12299935)
+--- testing: '123e5xyz' - '-44' ---
+float(12300044)
+--- testing: '123e5xyz' - '1.2' ---
+float(12299998.8)
+--- testing: '123e5xyz' - '-7.7' ---
+float(12300007.7)
+--- testing: '123e5xyz' - 'abc' ---
+float(12300000)
+--- testing: '123e5xyz' - '123abc' ---
+float(12299877)
+--- testing: '123e5xyz' - '123e5' ---
+float(0)
+--- testing: '123e5xyz' - '123e5xyz' ---
+float(0)
+--- testing: '123e5xyz' - ' 123abc' ---
+float(12299877)
+--- testing: '123e5xyz' - '123 abc' ---
+float(12299877)
+--- testing: '123e5xyz' - '123abc ' ---
+float(12299877)
+--- testing: '123e5xyz' - '3.4a' ---
+float(12299996.6)
+--- testing: '123e5xyz' - 'a5.9' ---
+float(12300000)
+--- testing: ' 123abc' - '0' ---
+int(123)
+--- testing: ' 123abc' - '65' ---
+int(58)
+--- testing: ' 123abc' - '-44' ---
+int(167)
+--- testing: ' 123abc' - '1.2' ---
+float(121.8)
+--- testing: ' 123abc' - '-7.7' ---
+float(130.7)
+--- testing: ' 123abc' - 'abc' ---
+int(123)
+--- testing: ' 123abc' - '123abc' ---
+int(0)
+--- testing: ' 123abc' - '123e5' ---
+float(-12299877)
+--- testing: ' 123abc' - '123e5xyz' ---
+float(-12299877)
+--- testing: ' 123abc' - ' 123abc' ---
+int(0)
+--- testing: ' 123abc' - '123 abc' ---
+int(0)
+--- testing: ' 123abc' - '123abc ' ---
+int(0)
+--- testing: ' 123abc' - '3.4a' ---
+float(119.6)
+--- testing: ' 123abc' - 'a5.9' ---
+int(123)
+--- testing: '123 abc' - '0' ---
+int(123)
+--- testing: '123 abc' - '65' ---
+int(58)
+--- testing: '123 abc' - '-44' ---
+int(167)
+--- testing: '123 abc' - '1.2' ---
+float(121.8)
+--- testing: '123 abc' - '-7.7' ---
+float(130.7)
+--- testing: '123 abc' - 'abc' ---
+int(123)
+--- testing: '123 abc' - '123abc' ---
+int(0)
+--- testing: '123 abc' - '123e5' ---
+float(-12299877)
+--- testing: '123 abc' - '123e5xyz' ---
+float(-12299877)
+--- testing: '123 abc' - ' 123abc' ---
+int(0)
+--- testing: '123 abc' - '123 abc' ---
+int(0)
+--- testing: '123 abc' - '123abc ' ---
+int(0)
+--- testing: '123 abc' - '3.4a' ---
+float(119.6)
+--- testing: '123 abc' - 'a5.9' ---
+int(123)
+--- testing: '123abc ' - '0' ---
+int(123)
+--- testing: '123abc ' - '65' ---
+int(58)
+--- testing: '123abc ' - '-44' ---
+int(167)
+--- testing: '123abc ' - '1.2' ---
+float(121.8)
+--- testing: '123abc ' - '-7.7' ---
+float(130.7)
+--- testing: '123abc ' - 'abc' ---
+int(123)
+--- testing: '123abc ' - '123abc' ---
+int(0)
+--- testing: '123abc ' - '123e5' ---
+float(-12299877)
+--- testing: '123abc ' - '123e5xyz' ---
+float(-12299877)
+--- testing: '123abc ' - ' 123abc' ---
+int(0)
+--- testing: '123abc ' - '123 abc' ---
+int(0)
+--- testing: '123abc ' - '123abc ' ---
+int(0)
+--- testing: '123abc ' - '3.4a' ---
+float(119.6)
+--- testing: '123abc ' - 'a5.9' ---
+int(123)
+--- testing: '3.4a' - '0' ---
+float(3.4)
+--- testing: '3.4a' - '65' ---
+float(-61.6)
+--- testing: '3.4a' - '-44' ---
+float(47.4)
+--- testing: '3.4a' - '1.2' ---
+float(2.2)
+--- testing: '3.4a' - '-7.7' ---
+float(11.1)
+--- testing: '3.4a' - 'abc' ---
+float(3.4)
+--- testing: '3.4a' - '123abc' ---
+float(-119.6)
+--- testing: '3.4a' - '123e5' ---
+float(-12299996.6)
+--- testing: '3.4a' - '123e5xyz' ---
+float(-12299996.6)
+--- testing: '3.4a' - ' 123abc' ---
+float(-119.6)
+--- testing: '3.4a' - '123 abc' ---
+float(-119.6)
+--- testing: '3.4a' - '123abc ' ---
+float(-119.6)
+--- testing: '3.4a' - '3.4a' ---
+float(0)
+--- testing: '3.4a' - 'a5.9' ---
+float(3.4)
+--- testing: 'a5.9' - '0' ---
+int(0)
+--- testing: 'a5.9' - '65' ---
+int(-65)
+--- testing: 'a5.9' - '-44' ---
+int(44)
+--- testing: 'a5.9' - '1.2' ---
+float(-1.2)
+--- testing: 'a5.9' - '-7.7' ---
+float(7.7)
+--- testing: 'a5.9' - 'abc' ---
+int(0)
+--- testing: 'a5.9' - '123abc' ---
+int(-123)
+--- testing: 'a5.9' - '123e5' ---
+float(-12300000)
+--- testing: 'a5.9' - '123e5xyz' ---
+float(-12300000)
+--- testing: 'a5.9' - ' 123abc' ---
+int(-123)
+--- testing: 'a5.9' - '123 abc' ---
+int(-123)
+--- testing: 'a5.9' - '123abc ' ---
+int(-123)
+--- testing: 'a5.9' - '3.4a' ---
+float(-3.4)
+--- testing: 'a5.9' - 'a5.9' ---
+int(0)
+===DONE===