mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-15 13:06:38 +00:00
Compare commits
1189
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1a1c34a111 | ||
|
|
af81b9d973 | ||
|
|
e9e1ba64e9 | ||
|
|
2bb2bcdcce | ||
|
|
f237b06942 | ||
|
|
9958658fc3 | ||
|
|
527f581a6b | ||
|
|
76a5faaf8f | ||
|
|
0e6b470417 | ||
|
|
295c1cc04e | ||
|
|
df35a307cc | ||
|
|
c6779ec584 | ||
|
|
f87b27a84e | ||
|
|
bbc87a14eb | ||
|
|
c1ee9eeecf | ||
|
|
db4b1f7f46 | ||
|
|
5697c1a9ac | ||
|
|
7f57a366dc | ||
|
|
72c994d464 | ||
|
|
5302a164b1 | ||
|
|
72a009a2f2 | ||
|
|
79cd4dc1c3 | ||
|
|
e3eb1b9bed | ||
|
|
f6966f28d0 | ||
|
|
e207cc58ac | ||
|
|
67f6979df2 | ||
|
|
e468aa44a2 | ||
|
|
fc6d3652f9 | ||
|
|
375bf36e42 | ||
|
|
997925db9f | ||
|
|
fa0e4863a2 | ||
|
|
2e869a00ac | ||
|
|
171184b64d | ||
|
|
bdbcc4b6d3 | ||
|
|
f4cd343b6c | ||
|
|
e5db0d8077 | ||
|
|
68893b0cb4 | ||
|
|
caa0de9205 | ||
|
|
39f1f2fcd3 | ||
|
|
b89ab4a4d5 | ||
|
|
6d9165b332 | ||
|
|
b196fbece9 | ||
|
|
85122b5ae6 | ||
|
|
8ba0f7f275 | ||
|
|
8ae4fa2810 | ||
|
|
b6900cb61d | ||
|
|
9a6012ff21 | ||
|
|
ef0652c7f3 | ||
|
|
54e44a4707 | ||
|
|
602f26dc08 | ||
|
|
68f328560d | ||
|
|
1155200b02 | ||
|
|
a04472df2e | ||
|
|
521048a9ae | ||
|
|
4846f7e349 | ||
|
|
7c21b37a2f | ||
|
|
f8e5189286 | ||
|
|
9926736605 | ||
|
|
0139100668 | ||
|
|
083c7f05ca | ||
|
|
ff9f6404dd | ||
|
|
ee0c90556e | ||
|
|
5516f0a247 | ||
|
|
586ceb9d40 | ||
|
|
08433295c4 | ||
|
|
c6ec417654 | ||
|
|
63f4dc835e | ||
|
|
3e47b3cb7b | ||
|
|
168f127abb | ||
|
|
2e2a566c15 | ||
|
|
9f6936fc0c | ||
|
|
efc78b635b | ||
|
|
017fa36d3f | ||
|
|
c43fe1c6cf | ||
|
|
82264b0b45 | ||
|
|
7a9cd0a4fd | ||
|
|
36e950eb5f | ||
|
|
c8f8766461 | ||
|
|
7a97b74637 | ||
|
|
92642d0189 | ||
|
|
a029117eb5 | ||
|
|
accfde57ca | ||
|
|
94a3bb327e | ||
|
|
d7e424acbe | ||
|
|
979e8b5896 | ||
|
|
3c9eb61d04 | ||
|
|
98505945f2 | ||
|
|
6f128d2dd7 | ||
|
|
00f18d764a | ||
|
|
6928bdc6bf | ||
|
|
2a078d14c9 | ||
|
|
1993c9a384 | ||
|
|
ecf81d1529 | ||
|
|
bf428e90a5 | ||
|
|
7deeb54fe1 | ||
|
|
6d078cea10 | ||
|
|
fdf4c22696 | ||
|
|
be49c27d17 | ||
|
|
0c9f9f8ef9 | ||
|
|
8cc2f5d576 | ||
|
|
3f6b49a340 | ||
|
|
393a686507 | ||
|
|
b8e0f7e78a | ||
|
|
40098256fb | ||
|
|
50a4e50d03 | ||
|
|
99d99a0ba0 | ||
|
|
f075e78ac1 | ||
|
|
477e2b315b | ||
|
|
98599a1c23 | ||
|
|
ea8fc31bf3 | ||
|
|
b84873aa96 | ||
|
|
7cf81e0fe0 | ||
|
|
620b1c63d0 | ||
|
|
2a05dfadb2 | ||
|
|
5a8c9a7d1c | ||
|
|
e1a402b6da | ||
|
|
f9137cddf6 | ||
|
|
07710a5fb9 | ||
|
|
1be447eb95 | ||
|
|
91e99495af | ||
|
|
b260f03830 | ||
|
|
0cd4039af2 | ||
|
|
c7047381f5 | ||
|
|
f422acca26 | ||
|
|
ecc9d28fed | ||
|
|
5e82a38f0a | ||
|
|
63b3528cb1 | ||
|
|
139996e1ac | ||
|
|
f89aae49a7 | ||
|
|
94eb3ed91b | ||
|
|
191bf235ed | ||
|
|
7d889d818a | ||
|
|
d70e63458f | ||
|
|
23d9af29d7 | ||
|
|
73219c9cb0 | ||
|
|
e538e493d7 | ||
|
|
2770262bad | ||
|
|
69158b5e18 | ||
|
|
f0435592a0 | ||
|
|
6eaef0712e | ||
|
|
64f7dafa74 | ||
|
|
16242cd2df | ||
|
|
11d5f9c7c4 | ||
|
|
3447b26334 | ||
|
|
12760053c1 | ||
|
|
52095f58a5 | ||
|
|
b024bedbdb | ||
|
|
5cb0b7609a | ||
|
|
2c841333ee | ||
|
|
474f6eef5e | ||
|
|
eb2659c7b2 | ||
|
|
f871988b88 | ||
|
|
b26d5f6077 | ||
|
|
2ff92b584e | ||
|
|
72fc33ef6a | ||
|
|
433d1a5d02 | ||
|
|
d0796d9d68 | ||
|
|
b89c7fcf8f | ||
|
|
884b06e303 | ||
|
|
e94f26f356 | ||
|
|
b441b275b3 | ||
|
|
f60df047f1 | ||
|
|
ddc1871576 | ||
|
|
24c806c41b | ||
|
|
91e8740fe4 | ||
|
|
9307163e67 | ||
|
|
b17d0085f3 | ||
|
|
0aa09167c1 | ||
|
|
eb3f8fda65 | ||
|
|
32b432f878 | ||
|
|
12bc950491 | ||
|
|
cecbe87656 | ||
|
|
74ae13f933 | ||
|
|
074b4e51f0 | ||
|
|
43cc8937b2 | ||
|
|
366c113156 | ||
|
|
9ee4848c3f | ||
|
|
f5bf263b88 | ||
|
|
3587185a89 | ||
|
|
7985002fc6 | ||
|
|
fa0efe45e0 | ||
|
|
c70e307e77 | ||
|
|
cfd8f6d775 | ||
|
|
30dc58671d | ||
|
|
ba144fd417 | ||
|
|
c932082f7b | ||
|
|
84d594e4b6 | ||
|
|
da068e5291 | ||
|
|
adb1cd835d | ||
|
|
8d377a698a | ||
|
|
f67c0222fe | ||
|
|
47950d10cf | ||
|
|
77951494b7 | ||
|
|
f7e4ff1054 | ||
|
|
d07b041e8a | ||
|
|
1ef91c8494 | ||
|
|
2fe9599880 | ||
|
|
15a715ae73 | ||
|
|
beeddd8873 | ||
|
|
507112e44d | ||
|
|
08d3f07ced | ||
|
|
280e6464e8 | ||
|
|
785b9d76f8 | ||
|
|
21f5a00183 | ||
|
|
c29136bd08 | ||
|
|
6c49087e64 | ||
|
|
402d3eb0e0 | ||
|
|
35990e7c5b | ||
|
|
ec3a713fbb | ||
|
|
b59c171e23 | ||
|
|
6d12620591 | ||
|
|
e1a08e5d55 | ||
|
|
4799047e07 | ||
|
|
aafdc266bf | ||
|
|
619b218e9a | ||
|
|
40085b06f2 | ||
|
|
b121ffae92 | ||
|
|
0cb6cfcd87 | ||
|
|
f22626ba5a | ||
|
|
4903f48eaa | ||
|
|
3373aeff8e | ||
|
|
03547dc13c | ||
|
|
cd836153d6 | ||
|
|
bb2ec1c790 | ||
|
|
b0e393e543 | ||
|
|
e0660a267e | ||
|
|
e3e2a62d44 | ||
|
|
69fbaf7d10 | ||
|
|
4d34ae2946 | ||
|
|
2cfdcd265d | ||
|
|
859a017f95 | ||
|
|
f39d5a2f21 | ||
|
|
1f45d49a0c | ||
|
|
910850be51 | ||
|
|
96df4d2161 | ||
|
|
0e0df5e47c | ||
|
|
bf132de1eb | ||
|
|
ada2b7ca41 | ||
|
|
b24d4ddac9 | ||
|
|
26bcbca33b | ||
|
|
99c6da86f3 | ||
|
|
dc34874dc9 | ||
|
|
5e6724b122 | ||
|
|
79325e3c55 | ||
|
|
fd15282c77 | ||
|
|
336111e4e9 | ||
|
|
7f7c158096 | ||
|
|
3327653e19 | ||
|
|
b33ea59337 | ||
|
|
ea6de20d86 | ||
|
|
96810f0ae6 | ||
|
|
a09eadc95b | ||
|
|
99695744ac | ||
|
|
9f249298fc | ||
|
|
8ff31493b7 | ||
|
|
e041a39e25 | ||
|
|
734dfc8b75 | ||
|
|
374bef4bc4 | ||
|
|
7ea43ee23a | ||
|
|
20296c625d | ||
|
|
793956a0e1 | ||
|
|
a14ef42c0c | ||
|
|
67b4492c47 | ||
|
|
9025c2a891 | ||
|
|
cf2121887c | ||
|
|
b7a47a439b | ||
|
|
2b69d18e49 | ||
|
|
822400d78f | ||
|
|
2a528a158a | ||
|
|
279f8d4822 | ||
|
|
82626c1868 | ||
|
|
510ad20616 | ||
|
|
f393620b9b | ||
|
|
fef2b33e85 | ||
|
|
dd8c8d05e8 | ||
|
|
022d4fc0b6 | ||
|
|
e280715150 | ||
|
|
09fbf87a6c | ||
|
|
af40765f8f | ||
|
|
49c91f6e33 | ||
|
|
649152ca49 | ||
|
|
e56466edc8 | ||
|
|
ee944bd1b5 | ||
|
|
5d238efaa6 | ||
|
|
18ce620bdf | ||
|
|
2198abb1c4 | ||
|
|
b9424cdfaf | ||
|
|
72f910c012 | ||
|
|
b78b25a336 | ||
|
|
5096c8d232 | ||
|
|
59a410cb76 | ||
|
|
09cad322fa | ||
|
|
152d379950 | ||
|
|
c6f777da1f | ||
|
|
3edd2a69f2 | ||
|
|
a3e6be974f | ||
|
|
eaa89d2443 | ||
|
|
19b1e39830 | ||
|
|
c230fa2b76 | ||
|
|
63bfa32aee | ||
|
|
af387e49ba | ||
|
|
90d58d4668 | ||
|
|
39bceffc4a | ||
|
|
a1ac6e1ee3 | ||
|
|
83647013af | ||
|
|
cac7e107c6 | ||
|
|
fdf96bed47 | ||
|
|
77c36cd259 | ||
|
|
9be89ed6f6 | ||
|
|
b9ddb5cba6 | ||
|
|
ba1f56cb6d | ||
|
|
6066b01d1b | ||
|
|
3197e135fa | ||
|
|
11750c315d | ||
|
|
cd0cfdfc39 | ||
|
|
4450386ae0 | ||
|
|
0ecaf04f86 | ||
|
|
78b2aaa954 | ||
|
|
2fc92c9172 | ||
|
|
d0d1e42c75 | ||
|
|
78e0e02179 | ||
|
|
5081b960e5 | ||
|
|
493b67b518 | ||
|
|
16980248cc | ||
|
|
a83c2153f9 | ||
|
|
3b32190c91 | ||
|
|
ff95906878 | ||
|
|
73fcf22627 | ||
|
|
0d98b9a1d9 | ||
|
|
9dfb01d3b1 | ||
|
|
00b9764a41 | ||
|
|
6ed33cd46d | ||
|
|
43a3524f49 | ||
|
|
cc44f5a09c | ||
|
|
8a3b3e9365 | ||
|
|
80b4ee9f44 | ||
|
|
de85bf4060 | ||
|
|
19401951c0 | ||
|
|
ede06426ee | ||
|
|
89c0ba1685 | ||
|
|
f30f2ef733 | ||
|
|
8ab9984707 | ||
|
|
8a61fc9b6e | ||
|
|
1aab36e3f2 | ||
|
|
141ae73099 | ||
|
|
254992907c | ||
|
|
1fd7133d5a | ||
|
|
11b820bda3 | ||
|
|
c6a7e4cad4 | ||
|
|
857aae2bd7 | ||
|
|
7f0be4f49d | ||
|
|
b1080faf44 | ||
|
|
8c4b05ad66 | ||
|
|
c5e61d4bca | ||
|
|
1d44054407 | ||
|
|
1d48a1081c | ||
|
|
440ed3da7f | ||
|
|
b27d339ddb | ||
|
|
2526d4f752 | ||
|
|
7f91d94c1d | ||
|
|
5b021ac2fa | ||
|
|
eb4a23c5ca | ||
|
|
a3e6f47ea1 | ||
|
|
f2038206cc | ||
|
|
2326c077e7 | ||
|
|
a4e199018c | ||
|
|
33f46cfe00 | ||
|
|
35591acebd | ||
|
|
068ee42185 | ||
|
|
07bf252ef5 | ||
|
|
2c126513bb | ||
|
|
e602885e54 | ||
|
|
d32c991e44 | ||
|
|
74f8114a89 | ||
|
|
fb5d47b1fb | ||
|
|
c7b4ea7820 | ||
|
|
848b1cbb91 | ||
|
|
c8f090c13e | ||
|
|
bd27a1227e | ||
|
|
b1ac58f75b | ||
|
|
65c77514e4 | ||
|
|
1507d56fc6 | ||
|
|
afed25d648 | ||
|
|
5c98effea0 | ||
|
|
4ed53a6dce | ||
|
|
fb8e3abe88 | ||
|
|
df9fbb6a73 | ||
|
|
69c00b75bb | ||
|
|
b6e86f054c | ||
|
|
6aa6434abf | ||
|
|
ba1cfb71ae | ||
|
|
5c3fb1ec46 | ||
|
|
e2a13a5c50 | ||
|
|
ceeeed9d19 | ||
|
|
7893178d8d | ||
|
|
6c305edc9c | ||
|
|
e2a79ed73e | ||
|
|
296147ea6e | ||
|
|
c4be8ab831 | ||
|
|
e87a7388b7 | ||
|
|
2046298d47 | ||
|
|
38b7d577a3 | ||
|
|
7fbcb745ab | ||
|
|
9420637921 | ||
|
|
decd278a8d | ||
|
|
9bdaf6ab55 | ||
|
|
270414f3b5 | ||
|
|
40f54b6c21 | ||
|
|
b29b59dcd2 | ||
|
|
e9b8f37341 | ||
|
|
ffab827d01 | ||
|
|
6a752ac6df | ||
|
|
3126445073 | ||
|
|
436a7a9767 | ||
|
|
2c1d8c74bd | ||
|
|
8c32099c5e | ||
|
|
f852cf4c91 | ||
|
|
50293835bf | ||
|
|
08286bcb9f | ||
|
|
45e907a0ee | ||
|
|
1e7a23a376 | ||
|
|
6c8312fa03 | ||
|
|
ef71664817 | ||
|
|
9bd0045359 | ||
|
|
af3de070e5 | ||
|
|
50aef7ec83 | ||
|
|
cb0e56f7c7 | ||
|
|
9c07366bb0 | ||
|
|
0d5dd8829b | ||
|
|
45e96efd1d | ||
|
|
6aa06fc7fb | ||
|
|
e507b4c4ce | ||
|
|
bc890f08fb | ||
|
|
83928238c2 | ||
|
|
0cb6dd5671 | ||
|
|
aa02056fcb | ||
|
|
15de12187e | ||
|
|
d937ffa999 | ||
|
|
42e003cd6c | ||
|
|
a289952c47 | ||
|
|
455cd3d837 | ||
|
|
0018bc6ac5 | ||
|
|
3f05f1f6fd | ||
|
|
bca0912296 | ||
|
|
c07aeab868 | ||
|
|
6bd9f53a63 | ||
|
|
57f3c5b343 | ||
|
|
8f17ded3d7 | ||
|
|
9abc90728d | ||
|
|
12ddff7032 | ||
|
|
67940a9c29 | ||
|
|
83e7324dae | ||
|
|
cd32b4e2bb | ||
|
|
6f25b84a3a | ||
|
|
515aaeda10 | ||
|
|
a847d2c6fe | ||
|
|
fd088beb06 | ||
|
|
82559ff7e5 | ||
|
|
4a43566b19 | ||
|
|
57daf22d8f | ||
|
|
77f9d22a0e | ||
|
|
b8470c4ca0 | ||
|
|
fc2fef68ac | ||
|
|
1fbba60dcb | ||
|
|
df11ce1ece | ||
|
|
6b7f164803 | ||
|
|
1b131c46ad | ||
|
|
c94dee8696 | ||
|
|
0ad85237ea | ||
|
|
a019d99e3f | ||
|
|
f361b07629 | ||
|
|
864a08d1cb | ||
|
|
56a947a3f7 | ||
|
|
00b3df2ad3 | ||
|
|
6879ccfa7d | ||
|
|
b3c6a9dffc | ||
|
|
48d5519378 | ||
|
|
cc5fd27a0e | ||
|
|
5534e4381d | ||
|
|
f894c6ece7 | ||
|
|
c0667eeaff | ||
|
|
959aa4f596 | ||
|
|
3f1b9990a4 | ||
|
|
e942c16f7c | ||
|
|
6387c99f83 | ||
|
|
25848bff61 | ||
|
|
d5a59064f9 | ||
|
|
a382ede3e8 | ||
|
|
8589a7f473 | ||
|
|
8566193449 | ||
|
|
c72d39f763 | ||
|
|
4db96af53f | ||
|
|
ebaba40774 | ||
|
|
52bb8f78a0 | ||
|
|
49fbb7770b | ||
|
|
287ac21d5f | ||
|
|
9efa1d8914 | ||
|
|
10fabe9092 | ||
|
|
e0a2d149f5 | ||
|
|
ce582024a5 | ||
|
|
8af7bc2044 | ||
|
|
095fdf88ce | ||
|
|
d78c7c9421 | ||
|
|
fb927452c9 | ||
|
|
6ed7c8f3aa | ||
|
|
b96718ba20 | ||
|
|
f8217712a4 | ||
|
|
3034092111 | ||
|
|
7d8734e5ca | ||
|
|
b96a8a79ba | ||
|
|
786621893e | ||
|
|
d3571ea2a9 | ||
|
|
8684e7495f | ||
|
|
68b823564d | ||
|
|
9fe59f509c | ||
|
|
dcc62b53bf | ||
|
|
423982ac97 | ||
|
|
0c10470842 | ||
|
|
5a1c39f71d | ||
|
|
2600cf9c20 | ||
|
|
2d3d745bd9 | ||
|
|
d0ef6e9a95 | ||
|
|
934b97d611 | ||
|
|
d2d88e74a0 | ||
|
|
179c67a64b | ||
|
|
e3b8cf0f66 | ||
|
|
3afa134717 | ||
|
|
99a162bb8b | ||
|
|
af0e8612af | ||
|
|
e13b4c2c4e | ||
|
|
4035a8ebc0 | ||
|
|
78932ba2f9 | ||
|
|
335cac3c6a | ||
|
|
1bc2880c46 | ||
|
|
7ec48cb37f | ||
|
|
c96c5ca91f | ||
|
|
10da2d994b | ||
|
|
7a847f1086 | ||
|
|
b555062576 | ||
|
|
38ae7f47c0 | ||
|
|
db97db9430 | ||
|
|
5cdae5bdbb | ||
|
|
fe25997d44 | ||
|
|
48f4ea9fba | ||
|
|
a13e153942 | ||
|
|
4b1afad123 | ||
|
|
c9f6d5941e | ||
|
|
e8fcd7477c | ||
|
|
17ee976404 | ||
|
|
5b71d45eff | ||
|
|
0dd60dd1cd | ||
|
|
ecb986892c | ||
|
|
1f5310747e | ||
|
|
4ddde21059 | ||
|
|
e4bf2268bf | ||
|
|
6e8d7aa85d | ||
|
|
e6e823c844 | ||
|
|
0b40ec1f19 | ||
|
|
815d8a9743 | ||
|
|
542d413277 | ||
|
|
257405eda6 | ||
|
|
8c01bf9ffb | ||
|
|
58bae48bf4 | ||
|
|
3fea65b0dc | ||
|
|
20c4198341 | ||
|
|
285316fcff | ||
|
|
a6278717f5 | ||
|
|
66e901b9d5 | ||
|
|
6b81cef355 | ||
|
|
5b83920434 | ||
|
|
1797c6870e | ||
|
|
a47f464e6e | ||
|
|
7cefd7792c | ||
|
|
0e6b39f515 | ||
|
|
ff2a77b1d3 | ||
|
|
51431a7660 | ||
|
|
0b4fc7c768 | ||
|
|
d271071067 | ||
|
|
a22a6711ad | ||
|
|
10a6af6bd0 | ||
|
|
226c56fe76 | ||
|
|
bffb8c406c | ||
|
|
d62163292f | ||
|
|
bfed3520c9 | ||
|
|
93af1c1f84 | ||
|
|
fb7efdab86 | ||
|
|
a091268eef | ||
|
|
0806c6c804 | ||
|
|
79e53b202c | ||
|
|
184b2e5d20 | ||
|
|
a547182c79 | ||
|
|
297f069eb6 | ||
|
|
09d9338040 | ||
|
|
7966ff120b | ||
|
|
b89637687d | ||
|
|
d2219c0a1a | ||
|
|
6b4b1e7431 | ||
|
|
521917bdfa | ||
|
|
741c74a25e | ||
|
|
9d7e023e37 | ||
|
|
20aa854940 | ||
|
|
2c05c8c6b3 | ||
|
|
dd23eb0c88 | ||
|
|
addd471501 | ||
|
|
e73b3b0dc4 | ||
|
|
e8f3167cd3 | ||
|
|
0b31350607 | ||
|
|
aaa16ad82b | ||
|
|
39c1705848 | ||
|
|
38002b9f7f | ||
|
|
c9aedbdda1 | ||
|
|
b355edcc3a | ||
|
|
2399b208db | ||
|
|
76b92b6d5d | ||
|
|
c77bcba737 | ||
|
|
cc7342ef72 | ||
|
|
aad63942b8 | ||
|
|
268808ad76 | ||
|
|
a2fa9bbe84 | ||
|
|
c5e892b213 | ||
|
|
cd34e1c27a | ||
|
|
241e66a708 | ||
|
|
a7b240b337 | ||
|
|
ad61002dc4 | ||
|
|
9d53e19697 | ||
|
|
6c5e9cc6e4 | ||
|
|
01fe5a0f22 | ||
|
|
06877d0064 | ||
|
|
40e44e99d6 | ||
|
|
1e768865dc | ||
|
|
3dff7a7dba | ||
|
|
95f8148f18 | ||
|
|
43bbbe8899 | ||
|
|
33329c065c | ||
|
|
4e68effc2e | ||
|
|
f54f453209 | ||
|
|
55ff728d73 | ||
|
|
af88e0b52c | ||
|
|
7588023b65 | ||
|
|
4b64dbb9a1 | ||
|
|
e206802652 | ||
|
|
921eb8939b | ||
|
|
28a2fe07b4 | ||
|
|
efe310579e | ||
|
|
ed10530eb5 | ||
|
|
f0dd5f5d52 | ||
|
|
9069dde1a4 | ||
|
|
eb923bf6fc | ||
|
|
4ef905ae59 | ||
|
|
d3ac984385 | ||
|
|
0261432888 | ||
|
|
addad71048 | ||
|
|
dc8d09bbbd | ||
|
|
90b9d6241e | ||
|
|
5c28db4a9c | ||
|
|
40f32634c2 | ||
|
|
1ad841d53a | ||
|
|
3067f6a937 | ||
|
|
a0a2b24df5 | ||
|
|
7b016d72a1 | ||
|
|
f0a8003c23 | ||
|
|
45c85130af | ||
|
|
f765f73e5f | ||
|
|
2821378c33 | ||
|
|
06d76f722d | ||
|
|
37781a5a84 | ||
|
|
6f1b3ea73a | ||
|
|
62ec6b17a6 | ||
|
|
84c9050805 | ||
|
|
143badba52 | ||
|
|
90fd8fd7e8 | ||
|
|
ca854215db | ||
|
|
b8383203a2 | ||
|
|
796d9cd783 | ||
|
|
510bee631f | ||
|
|
d0ee4977e7 | ||
|
|
b0ef04af84 | ||
|
|
c5254dbc1d | ||
|
|
f159642284 | ||
|
|
539f67ed8f | ||
|
|
fe9a826605 | ||
|
|
21290220f7 | ||
|
|
5d0ee5b518 | ||
|
|
4c22d54e23 | ||
|
|
2d098d1856 | ||
|
|
cab5c25dc2 | ||
|
|
fb8aedb046 | ||
|
|
7c6f0bd42b | ||
|
|
3a5501e0d4 | ||
|
|
d56933b179 | ||
|
|
9d82ead2bc | ||
|
|
e79091eb13 | ||
|
|
9f62beabfd | ||
|
|
aeaf26b86d | ||
|
|
a1fdbe88a6 | ||
|
|
0affea112a | ||
|
|
ebf7807668 | ||
|
|
fda3f33554 | ||
|
|
0cfa8b1a66 | ||
|
|
793800c78e | ||
|
|
28b73af90f | ||
|
|
fd784655a2 | ||
|
|
2ea0137d6c | ||
|
|
87b2a52a16 | ||
|
|
7dcf89d7d5 | ||
|
|
86a022f7c7 | ||
|
|
a3ba415e91 | ||
|
|
e20d798623 | ||
|
|
1ac512f547 | ||
|
|
26f2367d2d | ||
|
|
7ed3c4536d | ||
|
|
2fd4e8146c | ||
|
|
20fece8f76 | ||
|
|
36722ebc31 | ||
|
|
d6756845e8 | ||
|
|
e99013d039 | ||
|
|
9beffb1971 | ||
|
|
38af2c5741 | ||
|
|
921294e0d7 | ||
|
|
46c508e92c | ||
|
|
adcfdf7fa4 | ||
|
|
19f89a22c0 | ||
|
|
4938221a36 | ||
|
|
320a41603e | ||
|
|
d6e320d849 | ||
|
|
e5b21a95e1 | ||
|
|
82c2452bf9 | ||
|
|
9e1c9cad2d | ||
|
|
a074d2d66b | ||
|
|
0f15eeda46 | ||
|
|
ad0beee01f | ||
|
|
e4450111cc | ||
|
|
83bc0eb739 | ||
|
|
cc2bcefc47 | ||
|
|
e45dab8c49 | ||
|
|
9f4ff35af0 | ||
|
|
952a281aec | ||
|
|
3443d9be3f | ||
|
|
4d63c09661 | ||
|
|
d34bfe5c37 | ||
|
|
dd44c6a093 | ||
|
|
37e0738f3a | ||
|
|
030252067e | ||
|
|
4948afff78 | ||
|
|
93dfce49ca | ||
|
|
6b75f7bb82 | ||
|
|
b4e74fe9b5 | ||
|
|
e1f222858f | ||
|
|
37d1bfed25 | ||
|
|
4b2c457288 | ||
|
|
6e48ec45dd | ||
|
|
af85497e8f | ||
|
|
3d88f40d51 | ||
|
|
f132df4f66 | ||
|
|
aa15254e41 | ||
|
|
feb142cb79 | ||
|
|
8e26df9523 | ||
|
|
abffe87d42 | ||
|
|
e8de152ddd | ||
|
|
e5909f149c | ||
|
|
a61d445360 | ||
|
|
ce22f44493 | ||
|
|
7210ab5695 | ||
|
|
58ac8d559d | ||
|
|
83e33eac02 | ||
|
|
dc1c6f74c8 | ||
|
|
76cf8c0636 | ||
|
|
5daef5cd4a | ||
|
|
fa8a77a466 | ||
|
|
386cf7889f | ||
|
|
be9e02fd74 | ||
|
|
76872ee86e | ||
|
|
99c875a03d | ||
|
|
305ae11a3f | ||
|
|
48658c2512 | ||
|
|
506bd484dc | ||
|
|
aa54d9e385 | ||
|
|
c0481701be | ||
|
|
67a2cca930 | ||
|
|
7f47814c4e | ||
|
|
4d503a8807 | ||
|
|
3725bf6d5f | ||
|
|
1b894c90e7 | ||
|
|
7a1b48eeff | ||
|
|
3444305c5d | ||
|
|
44bec384ed | ||
|
|
e647140a82 | ||
|
|
993b689a2e | ||
|
|
70105187db | ||
|
|
5f82777275 | ||
|
|
5d2180835a | ||
|
|
ebb9408202 | ||
|
|
e2b093bfcb | ||
|
|
3322064025 | ||
|
|
a2e06e6dc8 | ||
|
|
034e8692b7 | ||
|
|
3b481cef64 | ||
|
|
0475096ea1 | ||
|
|
6d754185df | ||
|
|
b925a9248b | ||
|
|
210f091022 | ||
|
|
4c61a3f27e | ||
|
|
24bdf0e368 | ||
|
|
161ab0aa50 | ||
|
|
b73d2a94ae | ||
|
|
d3f2d039a5 | ||
|
|
738ff1277a | ||
|
|
74474a1ef8 | ||
|
|
fcd0a1e790 | ||
|
|
32c5a87a14 | ||
|
|
e2d606e18b | ||
|
|
bf348c8c46 | ||
|
|
df7bfe0a0f | ||
|
|
70a8f9313b | ||
|
|
93cf41436b | ||
|
|
4e51d2ec73 | ||
|
|
17db5db759 | ||
|
|
e1f08c8297 | ||
|
|
1fe8fded5f | ||
|
|
a81b0b5d62 | ||
|
|
c2e04e8364 | ||
|
|
bab1ce1429 | ||
|
|
788ac84cf4 | ||
|
|
f5f04f2214 | ||
|
|
c73237b7b9 | ||
|
|
3b27cd22b6 | ||
|
|
ed39fac5d2 | ||
|
|
c969e9005b | ||
|
|
9f28e21bb1 | ||
|
|
1c7fa8fb4c | ||
|
|
28bc39500a | ||
|
|
f018ec9024 | ||
|
|
62849e3fee | ||
|
|
5aea16e06b | ||
|
|
2caf386764 | ||
|
|
34d1d2eed0 | ||
|
|
06b4c66f02 | ||
|
|
5160f532af | ||
|
|
648aaf250a | ||
|
|
38c095a44f | ||
|
|
4f33b594ac | ||
|
|
f3ad3a770e | ||
|
|
b6762a8991 | ||
|
|
3b61fd8286 | ||
|
|
79d58abf65 | ||
|
|
37e8ce097c | ||
|
|
f199649ad6 | ||
|
|
f7d22b60f0 | ||
|
|
1351bc4e86 | ||
|
|
f903d42867 | ||
|
|
0ca8dab47d | ||
|
|
c8d54ca3fe | ||
|
|
a87f7117ff | ||
|
|
76065b520a | ||
|
|
e5be1f55ad | ||
|
|
d5c9a6efc4 | ||
|
|
1bd2791cd4 | ||
|
|
a6340d27ae | ||
|
|
c4b5196d0b | ||
|
|
b1a0a4d3e4 | ||
|
|
074b58b7f1 | ||
|
|
d042fd0675 | ||
|
|
c9805e7b92 | ||
|
|
91da96ba71 | ||
|
|
20b5c66e14 | ||
|
|
594fe5c398 | ||
|
|
d02356922a | ||
|
|
a20bba04d5 | ||
|
|
7b9e125e0c | ||
|
|
b6ddf71381 | ||
|
|
bc35767b46 | ||
|
|
4cf17cfc33 | ||
|
|
717e94c67a | ||
|
|
2041566a12 | ||
|
|
9295456f01 | ||
|
|
cb0fd15625 | ||
|
|
d114d0b0c8 | ||
|
|
29b9d79c2f | ||
|
|
2e15dda50e | ||
|
|
8b5a2d38c4 | ||
|
|
e001e11009 | ||
|
|
860c643448 | ||
|
|
7a7c447a17 | ||
|
|
0997342dff | ||
|
|
e029945a02 | ||
|
|
32e23d419f | ||
|
|
8853804482 | ||
|
|
2374641e58 | ||
|
|
3790227f9d | ||
|
|
c38ad55e8e | ||
|
|
c084d1c829 | ||
|
|
ceef5840ad | ||
|
|
03b0a479dd | ||
|
|
cf53dfaff3 | ||
|
|
7a03838430 | ||
|
|
0b157a6f84 | ||
|
|
5d8ae45309 | ||
|
|
22c68a8155 | ||
|
|
ce71724def | ||
|
|
d5d297d461 | ||
|
|
ecd42f9774 | ||
|
|
045b283a7d | ||
|
|
bd7c9ebeb0 | ||
|
|
31ce08253c | ||
|
|
43bb6e7c3e | ||
|
|
5c75e5b4f4 | ||
|
|
3285bd834b | ||
|
|
61d697d100 | ||
|
|
55b5b89ef7 | ||
|
|
d1b9c6e62e | ||
|
|
ca1b7e7b47 | ||
|
|
d12bbce277 | ||
|
|
c76e5dd0bd | ||
|
|
d5d2d6e30e | ||
|
|
a4d68b26e4 | ||
|
|
7bd41e0715 | ||
|
|
fd2e66bd05 | ||
|
|
ef952b0383 | ||
|
|
029b4678aa | ||
|
|
405a15043f | ||
|
|
256de924c7 | ||
|
|
489c2d739a | ||
|
|
f26145fa8c | ||
|
|
a8be5f419d | ||
|
|
79e3c88352 | ||
|
|
f4926a042e | ||
|
|
70650810ad | ||
|
|
6567a93a2a | ||
|
|
c5e8992942 | ||
|
|
c1c44ddcf3 | ||
|
|
8e3eee385e | ||
|
|
6d76fc2834 | ||
|
|
de64609fec | ||
|
|
b604bc7200 | ||
|
|
23eaae2211 | ||
|
|
df057bf78d | ||
|
|
f2e130c145 | ||
|
|
568525bbb5 | ||
|
|
2958037b2a | ||
|
|
794ceb7bad | ||
|
|
b529617499 | ||
|
|
770790af04 | ||
|
|
9282d4add6 | ||
|
|
f7ec7197f7 | ||
|
|
407c9833ef | ||
|
|
97e9bd1da0 | ||
|
|
b49e70f946 | ||
|
|
c0dd1f4d0b | ||
|
|
c64a4a1359 | ||
|
|
f92e99e83a | ||
|
|
a841027cca | ||
|
|
e35679618e | ||
|
|
ccd16d09c0 | ||
|
|
bcc95ae09b | ||
|
|
26c60afb5d | ||
|
|
47216d7de4 | ||
|
|
e3759c2823 | ||
|
|
0f6e099d7d | ||
|
|
6f61e84727 | ||
|
|
d2ec6b60da | ||
|
|
faae3e9ecf | ||
|
|
2c5368c013 | ||
|
|
452524fe3a | ||
|
|
8931a76101 | ||
|
|
7e1647e524 | ||
|
|
8561368787 | ||
|
|
8588db4b46 | ||
|
|
bac779d6b6 | ||
|
|
060589090d | ||
|
|
227fd7aa1f | ||
|
|
f00ea3c023 | ||
|
|
df03be1a3b | ||
|
|
eb0f324f70 | ||
|
|
de4408c9af | ||
|
|
d9c97cbd47 | ||
|
|
194044bbdb | ||
|
|
ad57583ba4 | ||
|
|
993b66b4c8 | ||
|
|
6e0d643783 | ||
|
|
f6bffb69c5 | ||
|
|
9998f67c91 | ||
|
|
f0b7941067 | ||
|
|
a894611636 | ||
|
|
c7069887a4 | ||
|
|
464d87e58b | ||
|
|
efcdcd80b6 | ||
|
|
2fba3bf13b | ||
|
|
61b06f1527 | ||
|
|
5603bef272 | ||
|
|
91d98d2986 | ||
|
|
9bca44df22 | ||
|
|
6f694fab9a | ||
|
|
a6a989d44c | ||
|
|
9a37c5588c | ||
|
|
d14d148f66 | ||
|
|
77fda18119 | ||
|
|
17a6ac36da | ||
|
|
9f5016ef7b | ||
|
|
13feaf3620 | ||
|
|
cdd37424a8 | ||
|
|
c1ba2927aa | ||
|
|
a69e6e2c79 | ||
|
|
b4eb20c8aa | ||
|
|
c98cbb6020 | ||
|
|
43fccbf2b9 | ||
|
|
090cee2bdc | ||
|
|
9181a464fe | ||
|
|
6218d2d998 | ||
|
|
680735fce8 | ||
|
|
083844f847 | ||
|
|
5040dbd5e8 | ||
|
|
89d57c7c67 | ||
|
|
5fdcc761a1 | ||
|
|
7d1dbff79d | ||
|
|
007bac315d | ||
|
|
23409a4bbf | ||
|
|
3040a34b21 | ||
|
|
04aefb4e18 | ||
|
|
a4e3f29771 | ||
|
|
30dd6a45d3 | ||
|
|
b65cdd0793 | ||
|
|
26e22f34fa | ||
|
|
b828d1939f | ||
|
|
a349109e42 | ||
|
|
c009fc8915 | ||
|
|
a3899eda3e | ||
|
|
c554031b24 | ||
|
|
9db4812366 | ||
|
|
c8a694eb45 | ||
|
|
2a6442190c | ||
|
|
0db4f06f13 | ||
|
|
3dc920d4ea | ||
|
|
ff95fbd692 | ||
|
|
27dcd0e5fb | ||
|
|
9955794367 | ||
|
|
6434290092 | ||
|
|
7e80ad9407 | ||
|
|
cfedafff67 | ||
|
|
bc2b546dcc | ||
|
|
80d2409fd8 | ||
|
|
6d41d020df | ||
|
|
4167b0a4ce | ||
|
|
d7b30e457a | ||
|
|
ff514e208e | ||
|
|
7e5f0a8380 | ||
|
|
ffd09c0961 | ||
|
|
83aba2c5b9 | ||
|
|
27c32bab35 | ||
|
|
ae49128df4 | ||
|
|
4ad45f6566 | ||
|
|
4bd12c4673 | ||
|
|
52c2d6c235 | ||
|
|
85f738261f | ||
|
|
7807477a87 | ||
|
|
587de83684 | ||
|
|
a5ce18dd47 | ||
|
|
6447c82454 | ||
|
|
8f06575c23 | ||
|
|
2b46d621e6 | ||
|
|
67032ecdf0 | ||
|
|
5e7b464517 | ||
|
|
7cc5c04b47 | ||
|
|
efd7846d34 | ||
|
|
bfbbe4110e | ||
|
|
3a10e5c078 | ||
|
|
09a575a20f | ||
|
|
69650d0ebf | ||
|
|
e72d044f9f | ||
|
|
55a3d5f8b1 | ||
|
|
e5a556757e | ||
|
|
633aff5541 | ||
|
|
727109283d | ||
|
|
607467451d | ||
|
|
ac38b635cb | ||
|
|
a640896685 | ||
|
|
d85fc29edf | ||
|
|
7d3c91bed3 | ||
|
|
82dc0875cb | ||
|
|
f42784219a | ||
|
|
725260ea0f | ||
|
|
2274c18cc6 | ||
|
|
9100e9efde | ||
|
|
83df9beca2 | ||
|
|
b33de5d0aa | ||
|
|
19d1d24d60 | ||
|
|
f752fd4836 | ||
|
|
909894682d | ||
|
|
c5c162d182 | ||
|
|
3a97c49489 | ||
|
|
42ae6b508e | ||
|
|
02dd014013 | ||
|
|
bc25fc52bf | ||
|
|
2b229635c2 | ||
|
|
c8cfd3b99a | ||
|
|
c1e84f1fff | ||
|
|
756f3f60ca | ||
|
|
d2fe65c191 | ||
|
|
93583f9680 | ||
|
|
8de1ecef64 | ||
|
|
5d8567b83b | ||
|
|
51e0891f0b | ||
|
|
63c11738f8 | ||
|
|
7efde494d7 | ||
|
|
6e8438633b | ||
|
|
fb045249e5 | ||
|
|
e7577d57cd | ||
|
|
c69b76dc52 | ||
|
|
f9f456a9cd | ||
|
|
6df5384610 | ||
|
|
223cfe342f | ||
|
|
75b5ce3b8d | ||
|
|
eec0b67cd8 | ||
|
|
420352d8b5 | ||
|
|
c25a2f6cd2 | ||
|
|
3a46e8ab1f | ||
|
|
56a27267f3 | ||
|
|
c2c4fe75e1 | ||
|
|
9b661ea62e | ||
|
|
146a600711 | ||
|
|
1f65545121 | ||
|
|
b64823deb7 | ||
|
|
877b7c7ea7 | ||
|
|
4a8e75b990 | ||
|
|
fa14b60e68 | ||
|
|
8f70937bec | ||
|
|
f0dbacb715 | ||
|
|
0a63bd4d0b | ||
|
|
f932fe5ad4 | ||
|
|
636806a869 | ||
|
|
468dc98961 | ||
|
|
accdf2c64c | ||
|
|
448dbac84f | ||
|
|
1d2c53b249 | ||
|
|
9edf1dc617 | ||
|
|
3000c0be66 | ||
|
|
0d5a13ddda | ||
|
|
3cd6bc54bc | ||
|
|
502d68e1e7 | ||
|
|
c70105610a | ||
|
|
9fd3c30f94 | ||
|
|
3f6cb452ee | ||
|
|
cde4621907 | ||
|
|
78ccf4e0c2 | ||
|
|
3585581412 | ||
|
|
24434e7ba2 | ||
|
|
567c9daeae | ||
|
|
b8fbcae5b3 | ||
|
|
b1b4b0a6a7 | ||
|
|
3f8c011a9a | ||
|
|
dadbd426c4 | ||
|
|
803e6f5887 | ||
|
|
1d6fea0e55 | ||
|
|
97b338afe5 | ||
|
|
d8ce0568ef | ||
|
|
cd32cab680 | ||
|
|
f50ec4ea53 | ||
|
|
0a92fdba8a | ||
|
|
ee593ef3b1 | ||
|
|
a64c73121d | ||
|
|
0f474f9474 | ||
|
|
df61bae636 | ||
|
|
fca80f63fb | ||
|
|
e03eadf633 | ||
|
|
688cc5039a | ||
|
|
c327dec913 | ||
|
|
101a0f08ce | ||
|
|
4b7999cd0b | ||
|
|
3721cb9d8d | ||
|
|
f409fcd02a | ||
|
|
01b0f9d44d | ||
|
|
047ccbc0c2 | ||
|
|
e0cab44595 | ||
|
|
96964359af | ||
|
|
c52e519bc0 | ||
|
|
e181e3ac7b | ||
|
|
618e172ec8 | ||
|
|
7bcf3ef165 | ||
|
|
7810fc89fa | ||
|
|
e878249669 | ||
|
|
1d7d3a4307 | ||
|
|
c3b9d939e0 | ||
|
|
70e6d3d042 | ||
|
|
9b1de77959 | ||
|
|
a6cd2b4cec | ||
|
|
de4f3007e2 | ||
|
|
88bef568da | ||
|
|
66859a74de | ||
|
|
ef32c956f7 | ||
|
|
bd7e78c48b |
No files matched your search
@@ -8,7 +8,7 @@ define ____executor_globals
|
||||
end
|
||||
|
||||
document ____executor_globals
|
||||
portable way of accessing executor_globals
|
||||
portable way of accessing executor_globals, set $eg
|
||||
ZTS detection is automatically based on ext/standard module struct
|
||||
end
|
||||
|
||||
@@ -39,14 +39,18 @@ define printzv
|
||||
end
|
||||
|
||||
document printzv
|
||||
prints content of zval
|
||||
prints zval contents
|
||||
end
|
||||
|
||||
define ____printzv_contents
|
||||
set $zvalue = $arg0
|
||||
set $type = $zvalue->type
|
||||
|
||||
printf "(refcount=%d) ", $zvalue->refcount
|
||||
printf "(refcount=%d", $zvalue->refcount
|
||||
if $zvalue->is_ref
|
||||
printf ",is_ref"
|
||||
end
|
||||
printf ") "
|
||||
if $type == 0
|
||||
printf "NULL"
|
||||
end
|
||||
@@ -69,7 +73,7 @@ define ____printzv_contents
|
||||
if ! $arg1
|
||||
printf "{\n"
|
||||
set $ind = $ind + 1
|
||||
____print_ht $zvalue->value.ht
|
||||
____print_ht $zvalue->value.ht 1
|
||||
set $ind = $ind - 1
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
@@ -103,7 +107,7 @@ define ____printzv_contents
|
||||
printf "(%d): ", $ht->nNumOfElements
|
||||
printf "{\n"
|
||||
set $ind = $ind + 1
|
||||
____print_ht $ht
|
||||
____print_ht $ht 1
|
||||
set $ind = $ind - 1
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
@@ -188,12 +192,10 @@ define print_const_table
|
||||
end
|
||||
|
||||
define ____print_ht
|
||||
set $ht = $arg0
|
||||
set $ht = (HashTable*)$arg0
|
||||
set $p = $ht->pListHead
|
||||
|
||||
while $p != 0
|
||||
set $zval = *(zval **)$p->pData
|
||||
|
||||
set $i = $ind
|
||||
while $i > 0
|
||||
printf " "
|
||||
@@ -206,8 +208,18 @@ define ____print_ht
|
||||
else
|
||||
printf "%d => ", $p->h
|
||||
end
|
||||
|
||||
if $arg1 == 0
|
||||
printf "%p\n", (void*)$p->pData
|
||||
end
|
||||
if $arg1 == 1
|
||||
set $zval = *(zval **)$p->pData
|
||||
____printzv $zval 1
|
||||
end
|
||||
if $arg1 == 2
|
||||
printf "%s\n", (char*)$p->pData
|
||||
end
|
||||
|
||||
____printzv $zval 1
|
||||
set $p = $p->pListNext
|
||||
end
|
||||
end
|
||||
@@ -215,7 +227,7 @@ end
|
||||
define print_ht
|
||||
set $ind = 1
|
||||
printf "[0x%08x] {\n", $arg0
|
||||
____print_ht $arg0
|
||||
____print_ht $arg0 1
|
||||
printf "}\n"
|
||||
end
|
||||
|
||||
@@ -223,6 +235,28 @@ document print_ht
|
||||
dumps elements of HashTable made of zval
|
||||
end
|
||||
|
||||
define print_htptr
|
||||
set $ind = 1
|
||||
printf "[0x%08x] {\n", $arg0
|
||||
____print_ht $arg0 0
|
||||
printf "}\n"
|
||||
end
|
||||
|
||||
document print_htptr
|
||||
dumps elements of HashTable made of pointers
|
||||
end
|
||||
|
||||
define print_htstr
|
||||
set $ind = 1
|
||||
printf "[0x%08x] {\n", $arg0
|
||||
____print_ht $arg0 2
|
||||
printf "}\n"
|
||||
end
|
||||
|
||||
document print_htstr
|
||||
dumps elements of HashTable made of strings
|
||||
end
|
||||
|
||||
define ____print_ft
|
||||
set $ht = $arg0
|
||||
set $p = $ht->pListHead
|
||||
|
||||
+1
-1
@@ -256,7 +256,7 @@ that the first implementation include a file labeled 'EXPERIMENTAL'
|
||||
in the function directory, and that the functions follow the
|
||||
standard prefixing conventions during their initial implementation.
|
||||
|
||||
The file labelled 'EXPERIMENTAL' should include the following
|
||||
The file labeled 'EXPERIMENTAL' should include the following
|
||||
information:
|
||||
Any authoring information (known bugs, future directions of the module).
|
||||
Ongoing status notes which may not be appropriate for CVS comments.
|
||||
|
||||
+9
-9
@@ -3,21 +3,21 @@
|
||||
# Zend
|
||||
#
|
||||
|
||||
$(builddir)/zend_language_scanner.lo: $(builddir)/zend_language_parser.h
|
||||
$(builddir)/zend_ini_scanner.lo: $(builddir)/zend_ini_parser.h
|
||||
$(builddir)/zend_language_scanner.lo: $(srcdir)/zend_language_parser.h
|
||||
$(builddir)/zend_ini_scanner.lo: $(srcdir)/zend_ini_parser.h
|
||||
|
||||
$(builddir)/zend_language_scanner.c: $(srcdir)/zend_language_scanner.l
|
||||
$(srcdir)/zend_language_scanner.c: $(srcdir)/zend_language_scanner.l
|
||||
@$(LEX) -Pzend -S$(srcdir)/flex.skl -o$@ -i $(srcdir)/zend_language_scanner.l
|
||||
|
||||
$(builddir)/zend_language_parser.h: $(builddir)/zend_language_parser.c
|
||||
$(builddir)/zend_language_parser.c: $(srcdir)/zend_language_parser.y
|
||||
$(srcdir)/zend_language_parser.h: $(srcdir)/zend_language_parser.c
|
||||
$(srcdir)/zend_language_parser.c: $(srcdir)/zend_language_parser.y
|
||||
@$(YACC) -p zend -v -d $(srcdir)/zend_language_parser.y -o $@
|
||||
|
||||
$(builddir)/zend_ini_parser.h: $(builddir)/zend_ini_parser.c
|
||||
$(builddir)/zend_ini_parser.c: $(srcdir)/zend_ini_parser.y
|
||||
$(srcdir)/zend_ini_parser.h: $(srcdir)/zend_ini_parser.c
|
||||
$(srcdir)/zend_ini_parser.c: $(srcdir)/zend_ini_parser.y
|
||||
@$(YACC) -p ini_ -v -d $(srcdir)/zend_ini_parser.y -o $@
|
||||
|
||||
$(builddir)/zend_ini_scanner.c: $(srcdir)/zend_ini_scanner.l
|
||||
$(srcdir)/zend_ini_scanner.c: $(srcdir)/zend_ini_scanner.l
|
||||
@$(LEX) -Pini_ -S$(srcdir)/flex.skl -o$@ -i $(srcdir)/zend_ini_scanner.l
|
||||
|
||||
$(builddir)/zend_indent.lo $(builddir)/zend_highlight.lo $(builddir)/zend_compile.lo: $(builddir)/zend_language_parser.h
|
||||
$(builddir)/zend_indent.lo $(builddir)/zend_highlight.lo $(builddir)/zend_compile.lo: $(srcdir)/zend_language_parser.h
|
||||
+59
-14
@@ -13,22 +13,22 @@ all: $(all_targets)
|
||||
|
||||
build-modules: $(PHP_MODULES)
|
||||
|
||||
libphp5.la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
libphp$(PHP_MAJOR_VERSION).la: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(LIBTOOL) --mode=link $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -rpath $(phptempdir) $(EXTRA_LDFLAGS) $(LDFLAGS) $(PHP_RPATHS) $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@
|
||||
-@$(LIBTOOL) --silent --mode=install cp libphp5.la $(phptempdir)/libphp5.la >/dev/null 2>&1
|
||||
-@$(LIBTOOL) --silent --mode=install cp $@ $(phptempdir)/$@ >/dev/null 2>&1
|
||||
|
||||
libs/libphp5.bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp5.so
|
||||
libs/libphp$(PHP_MAJOR_VERSION).bundle: $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS)
|
||||
$(CC) $(MH_BUNDLE_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) $(PHP_GLOBAL_OBJS:.lo=.o) $(PHP_SAPI_OBJS:.lo=.o) $(PHP_FRAMEWORKS) $(EXTRA_LIBS) $(ZEND_EXTRA_LIBS) -o $@ && cp $@ libs/libphp$(PHP_MAJOR_VERSION).so
|
||||
|
||||
install: $(all_targets) $(install_targets)
|
||||
|
||||
install-sapi: $(OVERALL_TARGET)
|
||||
@echo "Installing PHP SAPI module: $(PHP_SAPI)"
|
||||
-@$(mkinstalldirs) $(INSTALL_ROOT)$(bindir)
|
||||
-@if test ! -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); then \
|
||||
-@if test ! -r $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME); then \
|
||||
for i in 0.0.0 0.0 0; do \
|
||||
if test -r $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i; then \
|
||||
$(LN_S) $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME).$$i $(phptempdir)/libphp5.$(SHLIB_DL_SUFFIX_NAME); \
|
||||
if test -r $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME).$$i; then \
|
||||
$(LN_S) $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME).$$i $(phptempdir)/libphp$(PHP_MAJOR_VERSION).$(SHLIB_DL_SUFFIX_NAME); \
|
||||
break; \
|
||||
fi; \
|
||||
done; \
|
||||
@@ -66,33 +66,78 @@ install-headers:
|
||||
fi \
|
||||
done; \
|
||||
fi
|
||||
|
||||
install-su: install-pear
|
||||
|
||||
test: all
|
||||
PHP_TEST_SETTINGS = -d 'open_basedir=' -d 'output_buffering=0' -d 'memory_limit=-1'
|
||||
PHP_TEST_SHARED_EXTENSIONS = ` \
|
||||
if test "x$(PHP_MODULES)" != "x"; then \
|
||||
for i in $(PHP_MODULES)""; do \
|
||||
. $$i; $(top_srcdir)/build/shtool echo -n -- " -d extension=$$dlname"; \
|
||||
done; \
|
||||
fi`
|
||||
|
||||
test: all
|
||||
-@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
|
||||
TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(PHP_EXECUTABLE) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php -d 'extension_dir=modules/' -d `( . $(PHP_MODULES) ; echo extension=$$dlname)` tests/; \
|
||||
$(PHP_EXECUTABLE) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -U -d extension_dir=modules/ $(PHP_TEST_SHARED_EXTENSIONS) tests/; \
|
||||
elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
|
||||
INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
|
||||
if test "$$INI_FILE"; then \
|
||||
$(EGREP) -v '^extension[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
|
||||
else \
|
||||
echo > $(top_builddir)/tmp-php.ini; \
|
||||
fi; \
|
||||
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(top_builddir)/$(SAPI_CLI_PATH) -d 'open_basedir=' -d 'safe_mode=0' -d 'output_buffering=0' -d 'memory_limit=-1' $(top_srcdir)/run-tests.php $(TESTS); \
|
||||
$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -U -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
|
||||
else \
|
||||
echo "ERROR: Cannot run tests without CLI sapi."; \
|
||||
fi
|
||||
|
||||
utest: all
|
||||
-@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
|
||||
INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
|
||||
if test "$$INI_FILE"; then \
|
||||
$(EGREP) -v '^extension[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
|
||||
else \
|
||||
echo > $(top_builddir)/tmp-php.ini; \
|
||||
fi; \
|
||||
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -u -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
|
||||
else \
|
||||
echo "ERROR: Cannot run tests without CLI sapi."; \
|
||||
fi
|
||||
|
||||
ntest: all
|
||||
-@if test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
|
||||
INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -r 'echo php_ini_loaded_file();'`; \
|
||||
if test "$$INI_FILE"; then \
|
||||
$(EGREP) -v '^extension[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
|
||||
else \
|
||||
echo > $(top_builddir)/tmp-php.ini; \
|
||||
fi; \
|
||||
TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
|
||||
TEST_PHP_SRCDIR=$(top_srcdir) \
|
||||
CC="$(CC)" \
|
||||
$(top_builddir)/$(SAPI_CLI_PATH) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -c $(top_builddir)/tmp-php.ini -N -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
|
||||
else \
|
||||
echo "ERROR: Cannot run tests without CLI sapi."; \
|
||||
fi
|
||||
|
||||
clean:
|
||||
find . -name \*.gcno -o -name \*.gcda | xargs rm -f
|
||||
find . -name \*.lo -o -name \*.o | xargs rm -f
|
||||
find . -name \*.la -o -name \*.a | xargs rm -f
|
||||
find . -name \*.so | xargs rm -f
|
||||
find . -name .libs -a -type d|xargs rm -rf
|
||||
rm -f libphp5.la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
rm -f libphp$(PHP_MAJOR_VERSION).la $(SAPI_CLI_PATH) $(OVERALL_TARGET) modules/* libs/*
|
||||
|
||||
distclean: clean
|
||||
rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php5.spec sapi/apache/libphp5.module buildmk.stamp
|
||||
rm -f config.cache config.log config.status Makefile.objects Makefile.fragments libtool main/php_config.h stamp-h php5.spec sapi/apache/libphp$(PHP_MAJOR_VERSION).module buildmk.stamp
|
||||
$(EGREP) define'.*include/php' $(top_srcdir)/configure | $(SED) 's/.*>//'|xargs rm -f
|
||||
find . -name Makefile | xargs rm -f
|
||||
|
||||
|
||||
@@ -1,10 +1,540 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
26 Apr 2007, PHP 5.2.2RC2
|
||||
08 Nov 2007 , PHP 5.2.5
|
||||
- Upgraded PCRE to version 7.3 (Nuno)
|
||||
- Added optional parameter $provide_object to debug_backtrace(). (Sebastian)
|
||||
- Added alpha support for imagefilter() IMG_FILTER_COLORIZE. (Pierre)
|
||||
- Added ability to control memory consumption between request using
|
||||
ZEND_MM_COMPACT environment variable. (Dmitry)
|
||||
|
||||
- Improved speed of array_intersect_key(), array_intersect_assoc(),
|
||||
array_uintersect_assoc(), array_diff_key(), array_diff_assoc() and
|
||||
array_udiff_assoc(). (Dmitry)
|
||||
|
||||
- Fixed move_uploaded_file() to always set file permissions of resulting file
|
||||
according to UMASK. (Andrew Sitnikov)
|
||||
- Fixed possible crash in ext/soap because of uninitialized value. (Zdash Urf)
|
||||
- Fixed regression in glob() when enforcing safe_mode/open_basedir checks on
|
||||
paths containing '*'. (Ilia)
|
||||
- Fixed "mail.force_extra_parameters" php.ini directive not to be modifiable
|
||||
in .htaccess due to the security implications - reported by SecurityReason.
|
||||
(Stas)
|
||||
- Fixed PDO crash when driver returns empty LOB stream. (Stas)
|
||||
- Fixed dl() to only accept filenames - reported by Laurent Gaffie. (Stas)
|
||||
- Fixed dl() to limit argument size to MAXPATHLEN (CVE-2007-4887).
|
||||
(Christian Hoffmann)
|
||||
- Fixed iconv_*() functions to limit argument sizes as workaround to libc
|
||||
bug (CVE-2007-4783, CVE-2007-4840 by Laurent Gaffie).
|
||||
(Christian Hoffmann, Stas)
|
||||
- Fixed missing brackets leading to build warning and error in the log.
|
||||
Win32 code. (Andrey)
|
||||
- Fixed leaks with multiple connects on one mysqli object. (Andrey)
|
||||
- Fixed endianness detection on MacOS when building universal binary.
|
||||
(Uwe Schindler, Christian Speich, Tony)
|
||||
- Fixed possible triggering of buffer overflows inside glibc
|
||||
implementations of the fnmatch(), setlocale() and glob() functions.
|
||||
Reported by Laurent Gaffie. (Ilia)
|
||||
- Fixed imagerectangle regression with 1x1 rectangle (libgd #106). (Pierre)
|
||||
- Fixed htmlentities/htmlspecialchars not to accept partial multibyte
|
||||
sequences. (Stas)
|
||||
|
||||
- Fixed bug #43196 (array_intersect_assoc() crashes with non-array input).
|
||||
(Jani)
|
||||
- Fixed bug #43139 (PDO ignores ATTR_DEFAULT_FETCH_MODE in some cases with
|
||||
fetchAll()). (Ilia)
|
||||
- Fixed bug #43137 (rmdir() and rename() do not clear statcache). (Jani)
|
||||
- Fixed bug #43130 (Bound parameters cannot have - in their name). (Ilia)
|
||||
- Fixed bug #43099 (XMLWriter::endElement() does not check # of params).
|
||||
(Ilia)
|
||||
- Fixed bug #43020 (Warning message is missing with shuffle() and more
|
||||
than one argument). (Scott)
|
||||
- Fixed bug #42976 (Crash when constructor for newInstance() or
|
||||
newInstanceArgs() fails) (Ilia)
|
||||
- Fixed bug #42943 (ext/mssql: Move *timeout initialization from RINIT
|
||||
to connect time). (Ilia)
|
||||
- Fixed bug #42917 (PDO::FETCH_KEY_PAIR doesn't work with setFetchMode).
|
||||
(Ilia)
|
||||
- Fixed bug #42890 (Constant "LIST" defined by mysqlclient and c-client).
|
||||
(Andrey)
|
||||
- Fixed bug #42869 (automatic session id insertion adds sessions id to
|
||||
non-local forms). (Ilia)
|
||||
- Fixed bug #42818 ($foo = clone(array()); leaks memory). (Dmitry)
|
||||
- Fixed bug #42817 (clone() on a non-object does not result in a fatal
|
||||
error). (Ilia)
|
||||
- Fixed bug #42785 (json_encode() formats doubles according to locale rather
|
||||
then following standard syntax). (Ilia)
|
||||
- Fixed bug #42783 (pg_insert() does not accept an empty list for
|
||||
insertion). (Ilia)
|
||||
- Fixed bug #42773 (WSDL error causes HTTP 500 Response). (Dmitry)
|
||||
- Fixed bug #42772 (Storing $this in a static var fails while handling a cast
|
||||
to string). (Dmitry)
|
||||
- Fixed bug #42767 (highlight_string() truncates trailing comment). (Ilia)
|
||||
- Fixed bug #42739 (mkdir() doesn't like a trailing slash when safe_mode is
|
||||
enabled). (Ilia)
|
||||
- Fixed bug #42703 (Exception raised in an iterator::current() causes segfault
|
||||
in FilterIterator) (Marcus)
|
||||
- Fixed bug #42699 (PHP_SELF duplicates path). (Dmitry)
|
||||
- Fixed bug #42654 (RecursiveIteratorIterator modifies only part of leaves)
|
||||
(Marcus)
|
||||
- Fixed bug #42643 (CLI segfaults if using ATTR_PERSISTENT). (Ilia)
|
||||
- Fixed bug #42637 (SoapFault : Only http and https are allowed). (Bill Moran)
|
||||
- Fixed bug #42629 (Dynamically loaded PHP extensions need symbols exported
|
||||
on MacOSX). (jdolecek at NetBSD dot org)
|
||||
- Fixed bug #42627 (bz2 extension fails to build with -fno-common).
|
||||
(dolecek at netbsd dot org)
|
||||
- Fixed Bug #42596 (session.save_path MODE option does not work). (Ilia)
|
||||
- Fixed bug #42590 (Make the engine recognize \v and \f escape sequences).
|
||||
(Ilia)
|
||||
- Fixed bug #42587 (behavior change regarding symlinked .php files). (Dmitry)
|
||||
- Fixed bug #42579 (apache_reset_timeout() does not exist). (Jani)
|
||||
- Fixed bug #42549 (ext/mysql failed to compile with libmysql 3.23). (Scott)
|
||||
- Fixed bug #42523 (PHP_SELF duplicates path). (Dmitry)
|
||||
- Fixed bug #42512 (ip2long('255.255.255.255') should return 4294967295 on
|
||||
64-bit PHP). (Derick)
|
||||
- Fixed bug #42506 (php_pgsql_convert() timezone parse bug) (nonunnet at
|
||||
gmail dot com, Ilia)
|
||||
- Fixed bug #42462 (Segmentation when trying to set an attribute in a
|
||||
DOMElement). (Rob)
|
||||
- Fixed bug #42453 (CGI SAPI does not shut down cleanly with -i/-m/-v cmdline
|
||||
options). (Dmitry)
|
||||
- Fixed bug #42452 (PDO classes do not expose Reflection API information).
|
||||
(Hannes)
|
||||
- Fixed bug #42468 (Write lock on file_get_contents fails when using a
|
||||
compression stream). (Ilia)
|
||||
- Fixed bug #42488 (SoapServer reports an encoding error and the error itself
|
||||
breaks). (Dmitry)
|
||||
- Fixed bug #42378 (mysqli_stmt_bind_result memory exhaustion). (Andrey)
|
||||
- Fixed bug #42359 (xsd:list type not parsed). (Dmitry)
|
||||
- Fixed bug #42326 (SoapServer crash). (Dmitry)
|
||||
- Fixed bug #42214 (SoapServer sends clients internal PHP errors). (Dmitry)
|
||||
- Fixed bug #42189 (xmlrpc_set_type() crashes php on invalid datetime
|
||||
values). (Ilia)
|
||||
- Fixed bug #42139 (XMLReader option constants are broken using XML()). (Rob)
|
||||
- Fixed bug #42086 (SoapServer return Procedure '' not present for WSIBasic
|
||||
compliant wsdl). (Dmitry)
|
||||
- Fixed bug #41822 (Relative includes broken when getcwd() fails). (Ab5602,
|
||||
Jani)
|
||||
- Fixed bug #41561 (Values set with php_admin_* in httpd.conf can be overwritten
|
||||
with ini_set()). (Stas, Jani)
|
||||
- Fixed bug #39651 (proc_open() append mode doesn't work on windows). (Nuno)
|
||||
|
||||
30 Aug 2007, PHP 5.2.4
|
||||
- Removed --enable-versioning configure option. (Jani)
|
||||
|
||||
- Upgraded PCRE to version 7.2 (Nuno)
|
||||
- Updated timezone database to version 2007.6. (Derick)
|
||||
|
||||
- Improved openssl_x509_parse() to return extensions in readable form. (Dmitry)
|
||||
|
||||
- Enabled changing the size of statement cache for non-persistent OCI8
|
||||
connections. (Chris Jones, Tony)
|
||||
|
||||
- Changed "display_errors" php.ini option to accept "stderr" as value which
|
||||
makes the error messages to be outputted to STDERR instead of STDOUT with
|
||||
CGI and CLI SAPIs (FR #22839). (Jani)
|
||||
- Changed error handler to send HTTP 500 instead of blank page on PHP errors.
|
||||
(Dmitry, Andrei Nigmatulin)
|
||||
- Changed mail() function to be always available. (Johannes)
|
||||
|
||||
- Added check for unknown options passed to configure. (Jani)
|
||||
- Added persistent connection status checker to pdo_pgsql.
|
||||
(Elvis Pranskevichus, Ilia)
|
||||
- Added support for ATTR_TIMEOUT inside pdo_pgsql driver. (Ilia)
|
||||
- Added php_ini_loaded_file() function which returns the path to the actual
|
||||
php.ini in use. (Jani)
|
||||
- Added GD version constants GD_MAJOR_VERSION, GD_MINOR_VERSION,
|
||||
GD_RELEASE_VERSION, GD_EXTRA_VERSION and GD_VERSION_STRING. (Pierre)
|
||||
- Added missing open_basedir checks to CGI.
|
||||
(anight at eyelinkmedia dot com, Tony)
|
||||
- Added missing format validator to unpack() function. (Ilia)
|
||||
- Added missing error check inside bcpowmod(). (Ilia)
|
||||
- Added CURLOPT_PRIVATE & CURLINFO_PRIVATE constants.
|
||||
(Andrey A. Belashkov, Tony)
|
||||
- Added missing MSG_EOR and MSG_EOF constants to sockets extension. (Jani)
|
||||
- Added PCRE_VERSION constant. (Tony)
|
||||
- Added ReflectionExtension::info() function to print the phpinfo()
|
||||
block for an extension. (Johannes)
|
||||
|
||||
- Implemented FR #41884 (ReflectionClass::getDefaultProperties() does not
|
||||
handle static attributes). (Tony)
|
||||
|
||||
- Fixed "Floating point exception" inside wordwrap().
|
||||
(Mattias Bengtsson, Ilia)
|
||||
- Fixed several integer overflows in ImageCreate(), ImageCreateTrueColor(),
|
||||
ImageCopyResampled() and ImageFilledPolygon() reported by Mattias Bengtsson.
|
||||
(Tony)
|
||||
- Fixed size calculation in chunk_split(). (Stas)
|
||||
- Fixed integer overflow in str[c]spn(). (Stas)
|
||||
- Fixed money_format() not to accept multiple %i or %n tokens.
|
||||
(Stas, Ilia)
|
||||
- Fixed zend_alter_ini_entry() memory_limit interruption
|
||||
vulnerability. (Ilia)
|
||||
- Fixed INFILE LOCAL option handling with MySQL extensions not to be
|
||||
allowed when open_basedir or safe_mode is active. (Stas)
|
||||
- Fixed session.save_path and error_log values to be checked against
|
||||
open_basedir and safe_mode (CVE-2007-3378) (Stas, Maksymilian Arciemowicz)
|
||||
- Fixed possible invalid read in glob() win32 implementation (CVE-2007-3806).
|
||||
(Tony)
|
||||
- Improved fix for MOPB-03-2007. (Ilia)
|
||||
- Corrected fix for CVE-2007-2872. (Ilia)
|
||||
|
||||
- Fixed possible crash in imagepsloadfont(), work around a bug in the pslib on
|
||||
Windows. (Pierre)
|
||||
- Fixed oci8 and PDO_OCI extensions to allow configuring with Oracle 11g
|
||||
client libraries. (Chris Jones)
|
||||
- Fixed EOF handling in case of reading from file opened in write only mode.
|
||||
(Dmitry)
|
||||
- Fixed var_export() to use the new H modifier so that it can generate
|
||||
parseable PHP code for floats, independent of the locale. (Derick)
|
||||
- Fixed regression introduced by the fix for the libgd bug #74. (Pierre)
|
||||
- Fixed SimpleXML's behavior when used with empty(). (Sara)
|
||||
- Fixed crash in OpenSSL extension because of non-string passphrase. (Dmitry)
|
||||
|
||||
- Fixed PECL Bug #11345 (PDO_OCI crash after National language Support "NLS"
|
||||
environment initialization error). (Chris Jones)
|
||||
- Fixed PECL bug #11216 (crash in ZipArchive::addEmptyDir when a directory
|
||||
already exists). (Pierre)
|
||||
|
||||
- Fixed bug #42848 (Status: header incorrect under FastCGI). (Dmitry)
|
||||
- Fixed bug #42368 (Incorrect error message displayed by pg_escape_string).
|
||||
(Ilia)
|
||||
- Fixed bug #42365 (glob() crashes and/or accepts way too many flags).
|
||||
(Jani)
|
||||
- Fixed Bug #42364 (Crash when using getRealPath with DirectoryIterator).
|
||||
(Johannes)
|
||||
- Fixed bug #42292 ($PHP_CONFIG not set for phpized builds). (Jani)
|
||||
- Fixed bug #42261 (header wrong for date field).
|
||||
(roberto at spadim dot com dot br, Ilia)
|
||||
- Fixed bug #42259 (SimpleXMLIterator loses ancestry). (Rob)
|
||||
- Fixed bug #42247 (ldap_parse_result() not defined under win32). (Jani)
|
||||
- Fixed bug #42243 (copy() does not output an error when the first arg is a
|
||||
dir). (Ilia)
|
||||
- Fixed bug #42242 (sybase_connect() crashes). (Ilia)
|
||||
- Fixed bug #42237 (stream_copy_to_stream returns invalid values for mmaped
|
||||
streams). (andrew dot minerd at sellingsource dot com, Ilia)
|
||||
- Fixed bug #42233 (Problems with æøå in extract()). (Jani)
|
||||
- Fixed bug #42222 (possible buffer overflow in php_openssl_make_REQ). (Pierre)
|
||||
- Fixed bug #42211 (property_exists() fails to find protected properties
|
||||
from a parent class). (Dmitry)
|
||||
- Fixed bug #42208 (substr_replace() crashes when the same array is passed
|
||||
more than once). (crrodriguez at suse dot de, Ilia)
|
||||
- Fixed bug #42198 (SCRIPT_NAME and PHP_SELF truncated when inside a userdir
|
||||
and using PATH_INFO). (Dmitry)
|
||||
- Fixed bug #42195 (C++ compiler required always). (Jani)
|
||||
- Fixed bug #42183 (classmap causes crash in non-wsdl mode). (Dmitry)
|
||||
- Fixed bug #42173 (oci8 INTERVAL and TIMESTAMP type fixes). (Chris)
|
||||
- Fixed bug #42151 (__destruct functions not called after catching a SoapFault
|
||||
exception). (Dmitry)
|
||||
- Fixed bug #42142 (substr_replace() returns FALSE when length > string length).
|
||||
(Ilia)
|
||||
- Fixed bug #42135 (Second call of session_start() causes creation of SID).
|
||||
(Ilia)
|
||||
- Fixed bug #42134 (oci_error() returns false after oci_new_collection() fails).
|
||||
(Tony)
|
||||
- Fixed bug #42119 (array_push($arr,&$obj) doesn't work with
|
||||
zend.ze1_compatibility_mode On). (Dmitry)
|
||||
- Fixed bug #42117 (bzip2.compress loses data in internal buffer).
|
||||
(Philip, Ilia)
|
||||
- Fixed bug #42112 (deleting a node produces memory corruption). (Rob)
|
||||
- Fixed bug #42107 (sscanf broken when using %2$s format parameters). (Jani)
|
||||
- Fixed bug #42090 (json_decode causes segmentation fault). (Hannes)
|
||||
- Fixed bug #42082 (NodeList length zero should be empty). (Hannes)
|
||||
- Fixed bug #42072 (No warning message for clearstatcache() with arguments).
|
||||
(Ilia)
|
||||
- Fixed bug #42071 (ini scanner allows using NULL as option name). (Jani)
|
||||
- Fixed bug #42027 (is_file() / is_dir() matches file/dirnames with wildcard char
|
||||
or trailing slash in Windows). (Dmitry)
|
||||
- Fixed bug #42019 (configure option --with-adabas=DIR does not work). (Jani)
|
||||
- Fixed bug #42015 (ldap_rename(): server error "DSA is unwilling to perform").
|
||||
(bob at mroczka dot com, Jani)
|
||||
- Fixed bug #42009 (is_a() and is_subclass_of() should NOT call autoload, in the
|
||||
same way as "instanceof" operator). (Dmitry)
|
||||
- Fixed bug #41989 (move_uploaded_file() & relative path in ZTS mode). (Tony)
|
||||
- Fixed bug #41984 (Hangs on large SoapClient requests). (Dmitry)
|
||||
- Fixed bug #41983 (Error Fetching http headers terminated by '\n'). (Dmitry)
|
||||
- Fixed bug #41973 (--with-ldap=shared fails with LDFLAGS="-Wl,--as-needed"). (Nuno)
|
||||
- Fixed bug #41971 (PDOStatement::fetch and PDOStatement::setFetchMode causes
|
||||
unexpected behavior). (Ilia)
|
||||
- Fixed bug #41964 (strtotime returns a timestamp for non-time string of
|
||||
pattern '(A|a) .+'). (Derick)
|
||||
- Fixed bug #41961 (Ensure search for hidden private methods does not stray from
|
||||
class hierarchy). (robin_fernandes at uk dot ibm dot com)
|
||||
- Fixed bug #41947 (SimpleXML incorrectly registers empty strings asnamespaces).
|
||||
(Rob)
|
||||
- Fixed bug #41929 (Foreach on object does not iterate over all visible properties).
|
||||
(Dmitry)
|
||||
- Fixed bug #41919 (crash in string to array conversion).
|
||||
(judas dot iscariote at gmail dot com, Ilia)
|
||||
- Fixed bug #41909 (var_export() is locale sensitive when exporting float
|
||||
values). (Derick)
|
||||
- Fixed bug #41908 (CFLAGS="-Os" ./configure --enable-debug fails).
|
||||
(christian at hoffie dot info, Tony)
|
||||
- Fixed bug #41904 (proc_open(): empty env array should cause empty environment
|
||||
to be passed to process). (Jani)
|
||||
- Fixed bug #41867 (SimpleXML: getName is broken). (Rob)
|
||||
- Fixed bug #41865 (fputcsv(): 2nd parameter is not optional). (Jani)
|
||||
- Fixed bug #41861 (SimpleXML: getNamespaces() returns the namespaces of a node's
|
||||
siblings). (Rob)
|
||||
- Fixed bug #41845 (pgsql extension does not compile with PostgreSQL <7.4). (Ilia)
|
||||
- Fixed bug #41844 (Format returns incorrect number of digits for negative years
|
||||
-0001 to -0999). (Derick)
|
||||
- Fixed bug #41842 (Cannot create years < 0100 & negative years with date_create
|
||||
or new DateTime). (Derick)
|
||||
- Fixed bug #41833 (addChild() on a non-existent node, no node created,
|
||||
getName() segfaults). (Rob)
|
||||
- Fixed bug #41831 (pdo_sqlite prepared statements convert resources to
|
||||
strings). (Ilia)
|
||||
- Fixed bug #41815 (Concurrent read/write fails when EOF is reached). (Sascha)
|
||||
- Fixed bug #41813 (segmentation fault when using string offset as an object).
|
||||
(judas dot iscariote at gmail dot com, Tony)
|
||||
- Fixed bug #41795 (checkdnsrr does not support DNS_TXT type).
|
||||
(lucas at facebook dot com, Tony)
|
||||
- Fixed bug #41773 (php_strip_whitespace() sends headers with errors
|
||||
suppressed). (Tony)
|
||||
- Fixed bug #41770 (SSL: fatal protocol error due to buffer issues). (Ilia)
|
||||
- Fixed bug #41765 (Recode crashes/does not work on amd64).
|
||||
(nexus at smoula dot net, Stas)
|
||||
- Fixed bug #41724 (libxml_get_last_error() - errors service request scope).
|
||||
(thekid at php dot net, Ilia)
|
||||
- Fixed bug #41717 (imagepolygon does not respect thickness). (Pierre)
|
||||
- Fixed bug #41713 (Persistent memory consumption on win32 since 5.2). (Dmitry)
|
||||
- Fixed bug #41711 (NULL temporary lobs not supported in OCI8).
|
||||
(Chris Jones, Tony)
|
||||
- Fixed bug #41709 (strtotime() does not handle 00.00.0000). (Derick)
|
||||
- Fixed bug #41698 (float parameters truncated to integer in prepared
|
||||
statements). (Ilia)
|
||||
- Fixed bug #41692 (ArrayObject shows weird behavior in respect to
|
||||
inheritance). (Tony)
|
||||
- Fixed bug #41691 (ArrayObject::exchangeArray hangs Apache). (Tony)
|
||||
- Fixed bug #41686 (Omitting length param in array_slice not possible). (Ilia)
|
||||
- Fixed bug #41685 (array_push() fails to warn when next index is
|
||||
already occupied). (Ilia)
|
||||
- Fixed bug #41655 (open_basedir bypass via glob()). (Ilia)
|
||||
- Fixed bug #41640 (get_class_vars produces error on class constants).
|
||||
(Johannes)
|
||||
- Fixed bug #41635 (SoapServer and zlib.output_compression with FastCGI
|
||||
result in major slowdown). (Dmitry)
|
||||
- Fixed bug #41633 (Crash instantiating classes with self-referencing
|
||||
constants). (Dmitry)
|
||||
- Fixed bug #41630 (segfault when an invalid color index is present in the
|
||||
image data). (Reported by Elliot <wccoder@gmail dot com>) (Pierre)
|
||||
- Fixed bug #41628 (PHP settings leak between Virtual Hosts in Apache 1.3).
|
||||
(Scott, manuel at mausz dot at)
|
||||
- Fixed bug #41608 (segfault on a weird code with objects and switch()).
|
||||
(Tony)
|
||||
- Fixed bug #41600 (url rewriter tags doesn't work with namespaced tags).
|
||||
(Ilia)
|
||||
- Fixed bug #41596 (Fixed a crash inside pdo_pgsql on some non-well-formed
|
||||
SQL queries). (Ilia)
|
||||
- Fixed bug #41594 (OCI8 statement cache is flushed too frequently). (Tony)
|
||||
- Fixed bug #41582 (SimpleXML crashes when accessing newly created element).
|
||||
(Tony)
|
||||
- Fixed bug #41576 (configure failure when using --without-apxs or some other
|
||||
SAPIs disabling options). (Jani)
|
||||
- Fixed bug #41567 (json_encode() double conversion is inconsistent with PHP).
|
||||
(Lucas, Ilia)
|
||||
- Fixed bug #41566 (SOAP Server not properly generating href attributes).
|
||||
(Dmitry)
|
||||
- Fixed bug #41555 (configure failure: regression caused by fix for #41265).
|
||||
(Jani)
|
||||
- Fixed bug #41527 (WDDX deserialize numeric string array key).
|
||||
(Matt, Ilia)
|
||||
- Fixed bug #41523 (strtotime('0000-00-00 00:00:00') is parsed as 1999-11-30).
|
||||
(Derick)
|
||||
- Fixed bug #41518 (file_exists() warns of open_basedir restriction on
|
||||
non-existent file). (Tony)
|
||||
- Fixed bug #41445 (parse_ini_file() has a problem with certain types of
|
||||
integer as sections). (Tony)
|
||||
- Fixed bug #41433 (DBA: configure fails to include correct db.h for db4).
|
||||
(Jani)
|
||||
- Fixed bug #41372 (Internal pointer of source array resets during array
|
||||
copying). (Dmitry)
|
||||
- Fixed bug #41350 (my_thread_global_end() error during request shutdown on
|
||||
Windows). (Scott, Andrey)
|
||||
- Fixed bug #41278 (get_loaded_extensions() should list Zend extensions).
|
||||
(Johannes)
|
||||
- Fixed bug #41127 (Memory leak in ldap_{first|next}_attribute functions).
|
||||
(Jani)
|
||||
- Fixed bug #40757 (get_object_vars get nothing in child class). (Dmitry)
|
||||
- Fixed bug #40705 (Iterating within function moves original array pointer).
|
||||
(Dmitry)
|
||||
- Fixed bug #40509 (key() function changed behaviour if global array is used
|
||||
within function). (Dmitry)
|
||||
- Fixed bug #40419 (Trailing slash in CGI request does not work). (Dmitry)
|
||||
- Fixed bug #39330 (apache2handler does not call shutdown actions before
|
||||
apache child die). (isk at ecommerce dot com, Gopal, Tony)
|
||||
- Fixed bug #39291 (ldap_sasl_bind() misses the sasl_authc_id parameter).
|
||||
(diafour at gmail dot com, Jani)
|
||||
- Fixed bug #37715 (array pointers resetting on copy). (Dmitry)
|
||||
- Fixed bug #37273 (Symlinks and mod_files session handler allow open_basedir
|
||||
bypass). (Ilia)
|
||||
- Fixed bug #36492 (Userfilters can leak buckets). (Sara)
|
||||
- Fixed bugs #36796, #36918, #41371 (stream_set_blocking() does not work).
|
||||
(Jani)
|
||||
- Fixed bug #35981 (pdo-pgsql should not use pkg-config when not present).
|
||||
(Jani)
|
||||
- Fixed bug #31892 (PHP_SELF incorrect without cgi.fix_pathinfo, but turning on
|
||||
screws up PATH_INFO). (Dmitry)
|
||||
- Fixed bug #21197 (socket_read() outputs error with PHP_NORMAL_READ).
|
||||
(Nuno, Jani)
|
||||
|
||||
31 May 2007, PHP 5.2.3
|
||||
- Changed CGI install target to php-cgi and 'make install' to install CLI
|
||||
when CGI is selected. (Jani)
|
||||
- Changed JSON maximum nesting depth from 20 to 128. (Rasmus)
|
||||
|
||||
- Improved compilation of heredocs and interpolated strings. (Matt, Dmitry)
|
||||
- Optimized out a couple of per-request syscalls. (Rasmus)
|
||||
- Optimized digest generation in md5() and sha1() functions. (Ilia)
|
||||
- Upgraded bundled SQLite 3 to version 3.3.17. (Ilia)
|
||||
|
||||
- Added "max_input_nesting_level" php.ini option to limit nesting level of
|
||||
input variables. Fix for MOPB-03-2007. (Stas)
|
||||
- Added a 4th parameter flag to htmlspecialchars() and htmlentities() that
|
||||
makes the function not encode existing html entities. (Ilia)
|
||||
- Added PDO::FETCH_KEY_PAIR mode that will fetch a 2 column result set into
|
||||
an associated array. (Ilia)
|
||||
- Added CURLOPT_TIMEOUT_MS and CURLOPT_CONNECTTIMEOUT_MS cURL constants. (Sara)
|
||||
- Added --ini switch to CLI that prints out configuration file names. (Marcus)
|
||||
- Added mysql_set_charset() to allow runtime altering of connection encoding.
|
||||
(Scott)
|
||||
|
||||
- Implemented FR #41416 (getColumnMeta() should also return table name). (Tony)
|
||||
|
||||
- Fixed an integer overflow inside chunk_split(). Identified by Gerhard Wagner.
|
||||
(Ilia)
|
||||
- Fixed SOAP extension's handler() to work even when
|
||||
"always_populate_raw_post_data" is off. (Ilia)
|
||||
- Fixed possible infinite loop in imagecreatefrompng. (libgd #86)
|
||||
(by Xavier Roche, CVE-2007-2756). (Pierre)
|
||||
- Fixed ext/filter Email Validation Vulnerability (MOPB-45 by Stefan Esser).
|
||||
(Ilia)
|
||||
- Fixed altering $this via argument named "this". (Dmitry)
|
||||
- Fixed PHP CLI usage of php.ini from the binary location. (Hannes)
|
||||
- Fixed segfault in strripos(). (Tony, Joxean Koret)
|
||||
- Fixed bug #41693 (scandir() allows empty directory names). (Ilia)
|
||||
- Fixed bug #41673 (json_encode breaks large numbers in arrays). (Ilia)
|
||||
- Fixed bug #41525 (ReflectionParameter::getPosition() not available). (Marcus)
|
||||
- Fixed bug #41511 (Compile failure under IRIX 6.5.30 building md5.c). (Jani)
|
||||
- Fixed bug #41504 (json_decode() incorrectly decodes JSON arrays with empty
|
||||
string keys). (Ilia)
|
||||
- Fixed bug #41492 (open_basedir/safe_mode bypass inside realpath()). (Ilia)
|
||||
- Fixed bug #41477 (no arginfo about SoapClient::__soapCall()). (Ilia)
|
||||
- Fixed bug #41455 (ext/dba/config.m4 pollutes global $LIBS and $LDFLAGS).
|
||||
(mmarek at suse dot cz, Tony)
|
||||
- Fixed bug #41442 (imagegd2() under output control). (Tony)
|
||||
- Fixed bug #41430 (Fatal error with negative values of maxlen parameter of
|
||||
file_get_contents()). (Tony)
|
||||
- Fixed bug #41423 (PHP assumes wrongly that certain ciphers are enabled in
|
||||
OpenSSL). (Pierre)
|
||||
- Fixed bug #41421 (Uncaught exception from a stream wrapper segfaults).
|
||||
(Tony, Dmitry)
|
||||
- Fixed bug #41403 (json_decode cannot decode floats if localeconv
|
||||
decimal_point is not '.'). (Tony)
|
||||
- Fixed bug #41401 (wrong unary operator precedence). (Stas)
|
||||
- Fixed bug #41394 (dbase_create creates file with corrupted header). (Tony)
|
||||
- Fixed bug #41390 (Clarify error message with invalid protocol scheme).
|
||||
(Scott)
|
||||
- Fixed bug #41378 (fastcgi protocol lacks support for Reason-Phrase in
|
||||
"Status:" header). (anight at eyelinkmedia dot com, Dmitry)
|
||||
- Fixed bug #41374 (whole text concats values of wrong nodes). (Rob)
|
||||
- Fixed bug #41358 (configure cannot determine SSL lib with libcurl >= 7.16.2).
|
||||
(Mike)
|
||||
- Fixed bug #41353 (crash in openssl_pkcs12_read() on invalid input). (Ilia)
|
||||
- Fixed bug #41351 (Invalid opcode with foreach ($a[] as $b)). (Dmitry, Tony)
|
||||
- Fixed bug #41347 (checkdnsrr() segfaults on empty hostname). (Scott)
|
||||
- Fixed bug #41337 (WSDL parsing doesn't ignore non soap bindings). (Dmitry)
|
||||
- Fixed bug #41326 (Writing empty tags with Xmlwriter::WriteElement[ns])
|
||||
(Pierre)
|
||||
- Fixed bug #41321 (downgrade read errors in getimagesize() to E_NOTICE).
|
||||
(Ilia)
|
||||
- Fixed bug #41304 (compress.zlib temp files left). (Dmitry)
|
||||
- Fixed bug #41293 (Fixed creation of HTTP_RAW_POST_DATA when there is no
|
||||
default post handler). (Ilia)
|
||||
- Fixed bug #41291 (FastCGI does not set SO_REUSEADDR).
|
||||
(fmajid at kefta dot com, Dmitry)
|
||||
- Fixed gd build when used with freetype 1.x (Pierre, Tony)
|
||||
- Fixed bug #41287 (Namespace functions don't allow xmlns definition to be
|
||||
optional). (Rob)
|
||||
- Fixed bug #41285 (Improved fix for CVE-2007-1887 to work with non-bundled
|
||||
sqlite2 lib). (Ilia)
|
||||
- Fixed bug #41283 (Bug with deserializing array key that are doubles or
|
||||
floats in wddx). (Ilia)
|
||||
- Fixed bug #41257 (lookupNamespaceURI does not work as expected). (Rob)
|
||||
- Fixed bug #41236 (Regression in timeout handling of non-blocking SSL
|
||||
connections during reads and writes). (Ilia)
|
||||
- Fixed bug #41134 (zend_ts_hash_clean not thread-safe).
|
||||
(marco dot cova at gmail dot com, Tony)
|
||||
- Fixed bug #41097 (ext/soap returning associative array as indexed without
|
||||
using WSDL). (Dmitry)
|
||||
- Fixed bug #41004 (minOccurs="0" and null class member variable). (Dmitry)
|
||||
- Fixed bug #39542 (Behavior of require/include different to < 5.2.0).
|
||||
(Dmitry)
|
||||
|
||||
03 May 2007, PHP 5.2.2
|
||||
- Improved bundled GD
|
||||
. Sync to 2.0.35
|
||||
. Added imagegrabwindow and imagegrabscreen, capture a screen or a
|
||||
window using its handle (Pierre)
|
||||
. colors allocated henceforth from the resulting image overwrite the palette
|
||||
colors (Rob Leslie)
|
||||
. Improved thread safety of the gif support (Roman Nemecek, Nuno, Pierre)
|
||||
. Use the dimension of the GIF frame to create the destination image (Pierre)
|
||||
. Load only once the local color map from a GIF data (Pierre)
|
||||
. Improved thread safety of the freetype cache (Scott MacVicar, Nuno, Pierre)
|
||||
. imagearc huge CPU usage with large angles, libgd bug #74 (Pierre)
|
||||
- Improved FastCGI SAPI to support external pipe and socket servers on win32.
|
||||
(Dmitry)
|
||||
- Improved Zend Memory Manager
|
||||
. guarantee of reasonable time for worst cases of best-fit free block
|
||||
searching algorithm. (Dmitry)
|
||||
. better cache usage and less fragmentation on erealloc() (Tony, Dmitry)
|
||||
- Improved SPL (Marcus)
|
||||
. Added SplFileInfo::getBasename(), DirectoryIterator::getBasename().
|
||||
. Added SplFileInfo::getLinkTarget(), SplFileInfo::getRealPath().
|
||||
. Made RecursiveFilterIterator::accept() abstract as stated in documentation.
|
||||
- Improved SOAP
|
||||
. Added ability to encode arrays with "SOAP-ENC:Array" type instead of WSDL
|
||||
type. To activate the ability use "feature"=>SOAP_USE_XSI_ARRAY_TYPE
|
||||
option in SoapClient/SoapServer constructors. (Rob, Dmitry)
|
||||
|
||||
- Added GMP_VERSION constant. (Tony)
|
||||
- Fixed commandline handling fro CLI and CGI. (Marcus, Johannes)
|
||||
- Added --ri switch to CLI which allows to check extension information. (Marcus)
|
||||
- Added tidyNode::getParent() method (John, Nuno)
|
||||
- Added openbasedir and safemode checks in zip:// stream wrapper and
|
||||
ZipArchive::open (Pierre)
|
||||
- Added php_pdo_sqlite_external.dll, a version of the PDO SQLite driver that
|
||||
links against an external sqlite3.dll. This provides Windows users to upgrade
|
||||
their sqlite3 version outside of the PHP release cycle. (Wez, Edin)
|
||||
- Added linenumbers to array returned by token_get_all(). (Johannes)
|
||||
|
||||
- Upgraded SQLite 3 to version 3.3.16 (Ilia)
|
||||
- Upgraded libraries bundled in the Windows distribution. (Edin)
|
||||
. c-client (imap) to version 2006e
|
||||
. libpq (PostgreSQL) to version 8.2.3
|
||||
. libmysql (MySQL) to version 5.0.37
|
||||
. openssl to version 0.9.8e
|
||||
- Upgraded PCRE to version 7.0 (Nuno)
|
||||
|
||||
- Updated timezone database to version 2007.5. (Derick)
|
||||
|
||||
- Fixed commandline handling for CLI and CGI. (Marcus, Johannes)
|
||||
- Fixed iterator_apply() with a callback using __call(). (Johannes)
|
||||
- Fixed possible multi bytes issues in openssl csr parser (Pierre)
|
||||
- Fixed shmop_open() with IPC_CREAT|IPC_EXCL flags on Windows.
|
||||
(Vladimir Kamaev, Tony).
|
||||
- Fixed possible leak in ZipArchive::extractTo when safemode checks fails (Ilia)
|
||||
- Fixed possible relative path issues in zip_open and TS mode (old API) (Pierre)
|
||||
- Fixed zend_llist_remove_tail (Michael Wallner, Dmitry)
|
||||
- Fixed a thread safety issue in gd gif read code (Nuno, Roman Nemecek)
|
||||
- Fixed CVE-2007-1001, GD wbmp used with invalid image size (Pierre)
|
||||
- Fixed unallocated memory access/double free in in array_user_key_compare()
|
||||
(MOPB-24 by Stefan Esser) (Stas)
|
||||
- Fixed wrong length calculation in unserialize S type
|
||||
(MOPB-29 by Stefan Esser) (Stas)
|
||||
|
||||
- Fixed bug #41215 (setAttribute return code reversed). (Ilia)
|
||||
- Fixed bug #41192 (Per Directory Values only work for one key). (Dmitry)
|
||||
- Fixed bug #41175 (addAttribute() fails to add an attribute with an empty
|
||||
value). (Ilia)
|
||||
- Fixed bug #41159 (mysql_pconnect() hash does not account for connect
|
||||
@@ -24,79 +554,20 @@ PHP NEWS
|
||||
- Fixed bug #41063 (chdir doesn't like root paths). (Dmitry)
|
||||
- Fixed bug #41061 ("visibility error" in ReflectionFunction::export()).
|
||||
(Johannes)
|
||||
- Fixed bug #41034 (json_encode() ignores null byte started keys in arrays).
|
||||
(Ilia)
|
||||
- Fixed bug #40935 (pdo_mysql does not raise an exception on empty
|
||||
fetchAll()). (Ilia)
|
||||
- Fixed bug #40861 (strtotime() doesn't handle double negative relative time
|
||||
units correctly). (Derick)
|
||||
- Fixed bug #40290 (strtotime() returns unexpected result with particular
|
||||
timezone offset). (Derick)
|
||||
- Fixed bug #39965 (Latitude and longitude are backwards in date_sun_info()).
|
||||
(Derick)
|
||||
- Fixed bug #39416 (Milliseconds in date()). (Derick)
|
||||
|
||||
|
||||
10 Apr 2007, PHP 5.2.2RC1
|
||||
- Improved bundled GD
|
||||
. Sync to 2.0.35
|
||||
. Added imagegrabwindow and imagegrabscreen, capture a screen or a
|
||||
window using its handle (Pierre)
|
||||
. colors allocated henceforth from the resulting image overwrite the palette
|
||||
colors (Rob Leslie)
|
||||
. Improved thread safety of the gif support (Roman Nemecek, Nuno, Pierre)
|
||||
. Use the dimension of the GIF frame to create the destination image (Pierre)
|
||||
. Load only once the local color map from a GIF data (Pierre)
|
||||
. Improved thread safety of the freetype cache (Scott MacVicar, Nuno, Pierre)
|
||||
. imagearc huge CPU usage with large angles, libgd bug #74 (Pierre)
|
||||
|
||||
- Upgraded libraries bundled in the Windows distribution. (Edin)
|
||||
. c-client (imap) to version 2006e
|
||||
. libpq (PostgreSQL) to version 8.2.3
|
||||
. libmysql (MySQL) to version 5.0.37
|
||||
. openssl to version 0.9.8e
|
||||
- Upgraded PCRE to version 7.0 (Nuno)
|
||||
- Updated timezone database to version 2007.3. (Derick)
|
||||
- Improved FastCGI SAPI to support external pipe and socket servers on win32.
|
||||
(Dmitry)
|
||||
- Improved Zend Memory Manager
|
||||
. guarantee of reasonable time for worst cases of best-fit free block
|
||||
searching algorithm. (Dmitry)
|
||||
. better cache usage and less fragmentation on erealloc() (Tony, Dmitry)
|
||||
- Improved SPL (Marcus)
|
||||
. Added SplFileInfo::getBasename(), DirectoryIterator::getBasename().
|
||||
. Added SplFileInfo::getLinkTarget(), SplFileInfo::getRealPath().
|
||||
. Made RecursiveFilterIterator::accept() abstract as stated in documentation.
|
||||
- Improved SOAP
|
||||
. Added ability to encode arrays with "SOAP-ENC:Array" type instead of WSDL
|
||||
type. To activate the ability use "feature"=>SOAP_USE_XSI_ARRAY_TYPE
|
||||
option in SoapClient/SoapServer constructors. (Rob, Dmitry)
|
||||
- Added --ri switch to CLI which allows to check extension information. (Marcus)
|
||||
- Added tidyNode::getParent() method (John, Nuno)
|
||||
- Added openbasedir and safemode checks in zip:// stream wrapper and
|
||||
ZipArchive::open (Pierre)
|
||||
- Added php_pdo_sqlite_external.dll, a version of the PDO SQLite driver that
|
||||
links against an external sqlite3.dll. This provides Windows users to upgrade
|
||||
their sqlite3 version outside of the PHP release cycle. (Wez, Edin)
|
||||
- Added linenumbers to array returned by token_get_all(). (Johannes)
|
||||
- Fixed possible multi bytes issues in openssl csr parser (Pierre)
|
||||
- Fixed shmop_open() with IPC_CREAT|IPC_EXCL flags on Windows.
|
||||
(Vladimir Kamaev, Tony).
|
||||
- Fixed possible leak in ZipArchive::extractTo when safemode checks fails (Ilia)
|
||||
- Fixed possible relative path issues in zip_open and TS mode (old API) (Pierre)
|
||||
- Fixed zend_llist_remove_tail (Michael Wallner, Dmitry)
|
||||
- Fixed a thread safety issue in gd gif read code (Nuno, Roman Nemecek)
|
||||
- Fixed CVE-2007-1001, GD wbmp used with invalid image size (Pierre)
|
||||
- Fixed bug #41043 (pdo_oci crash when freeing error text with persistent
|
||||
connection). (Tony)
|
||||
- Fixed bug #41037 (unregister_tick_function() inside the tick function crash PHP).
|
||||
(Tony)
|
||||
- Fixed bug #41034 (json_encode() ignores null byte started keys in arrays).
|
||||
(Ilia)
|
||||
- Fixed bug #41026 (segfault when calling "self::method()" in shutdown functions).
|
||||
(Tony)
|
||||
- Fixed bug #40999 (mcrypt_create_iv() not using random seed). (Ilia)
|
||||
- Fixed bug #40998 (long session array keys are truncated). (Tony)
|
||||
- Implement feature request #40947, allow a single filter as argument
|
||||
for filter_var_array (Pierre)
|
||||
- Fixed bug #40935 (pdo_mysql does not raise an exception on empty
|
||||
fetchAll()). (Ilia)
|
||||
- Fixed bug #40931 (open_basedir bypass via symlink and move_uploaded_file()).
|
||||
(Tony)
|
||||
- Fixed bug #40921 (php_default_post_reader crashes when post_max_size is
|
||||
@@ -107,7 +578,8 @@ PHP NEWS
|
||||
- Fixed bug #40883 (mysql_query() is allocating memory incorrectly). (Tony)
|
||||
- Fixed bug #40872 (inconsistency in offsetSet, offsetExists treatment of
|
||||
string enclosed integers). (Marcus)
|
||||
- Fixed bug #40861 (Multiple +/- on relative units breaks strtotime()). (Ilia)
|
||||
- Fixed bug #40861 (strtotime() doesn't handle double negative relative time
|
||||
units correctly). (Derick, Ilia)
|
||||
- Fixed bug #40854 (imap_mail_compose() creates an invalid terminator for
|
||||
multipart e-mails). (Ilia)
|
||||
- Fixed bug #40848 (sorting issue on 64-bit Solaris). (Wez)
|
||||
@@ -182,14 +654,19 @@ PHP NEWS
|
||||
(tuxracer69 at gmail dot com, Tony)
|
||||
- Fixed bug #40371 (pg_client_encoding() not working on Windows). (Edin)
|
||||
- Fixed bug #40352 (FCGI_WEB_SERVER_ADDRS function get lost). (Dmitry)
|
||||
- Fixed bug #40290 (strtotime() returns unexpected result with particular
|
||||
timezone offset). (Derick)
|
||||
- Fixed bug #40286 (PHP fastcgi with PHP_FCGI_CHILDREN don't kill children when
|
||||
parent is killed). (Dmitry)
|
||||
- Fixed bug #40261 (Extremely slow data handling due to memory fragmentation).
|
||||
(Dmitry)
|
||||
- Fixed bug #40236 (php -a function allocation eats memory). (Dmitry)
|
||||
- Fixed bug #40109 (iptcembed fails on non-jfif jpegs). (Tony)
|
||||
- Fixed bug #39965 (Latitude and longitude are backwards in date_sun_info()).
|
||||
(Derick)
|
||||
- Implement #39867 (openssl PKCS#12 support) (Marc Delling, Pierre)
|
||||
- Fixed bug #39836 (SplObjectStorage empty after unserialize). (Marcus)
|
||||
- Fixed bug #39416 (Milliseconds in date()). (Derick)
|
||||
- Fixed bug #39396 (stream_set_blocking crashes on Win32). (Ilia, maurice at
|
||||
iceblog dot de)
|
||||
- Fixed bug #39351 (relative include fails on Solaris). (Dmitry, Tony)
|
||||
@@ -205,8 +682,6 @@ PHP NEWS
|
||||
(jdolecek at netbsd dot org, Nuno)
|
||||
- Fixed PECL bug #10194 (crash in Oracle client when memory limit reached in
|
||||
the callback). (Tony)
|
||||
- Limit nesting level of input variables with max_input_nesting_level
|
||||
as fix for MOPB-03-2007 (Stas)
|
||||
- Fixed substr_compare and substr_count information leak (MOPB-14) (Stas, Ilia)
|
||||
- Fixed crash on op-assign where argument is string offset (Brian, Stas)
|
||||
- Fixed bug #38710 (data leakage because of nonexisting boundary checking in
|
||||
@@ -215,13 +690,10 @@ PHP NEWS
|
||||
(Rob)
|
||||
- Fixed bug #37013 (server hangs when returning circular object references).
|
||||
(Dmitry)
|
||||
- Fixed unallocated memory access/double free in in array_user_key_compare()
|
||||
(MOPB-24 by Stefan Esser) (Stas)
|
||||
- Fixed wrong length calculation in unserialize S type
|
||||
(MOPB-29 by Stefan Esser) (Stas)
|
||||
- Fixed bug #33664 Console window appears when using exec()
|
||||
(Richard Quadling, Stas)
|
||||
|
||||
|
||||
08 Feb 2007, PHP 5.2.1
|
||||
- Added read-timeout context option "timeout" for HTTP streams. (Hannes, Ilia).
|
||||
- Added CURLOPT_TCP_NODELAY constant to Curl extension. (Sara)
|
||||
@@ -1156,7 +1628,7 @@ PHP NEWS
|
||||
aborted" FastCGI err). (Dmitry)
|
||||
- Fixed bug #37192 (cc may complain about non-constant initializers in
|
||||
hash_adler.c). (Mike)
|
||||
- Fixed bug #37191 (chmod takes off sticky bit when safe_mode is On). (Tony)
|
||||
- Fixed bug #37191 (chmod takes off sticky bit when safe_mode is On). (Tony)
|
||||
- Fixed bug #37167 (PDO segfaults when throwing exception from the
|
||||
fetch handler). (Tony)
|
||||
- Fixed bug #37162 (wddx does not build as a shared extension).
|
||||
|
||||
+6
-4
@@ -39,9 +39,7 @@ HEAD Will become PHP 6.0. This CVS branch is for active development.
|
||||
PHP_5_2 Is used to release the PHP 5.2.x series. Only minor feature
|
||||
enhancements may go in here, but please keep that as infrequent as
|
||||
possible.
|
||||
PHP_5_1 Is used to release the PHP 5.1.x series. Only bugfixes are permitted
|
||||
on this branch (Consult the releasemaster prior to commit).
|
||||
PHP_5_0 This branch is closed.
|
||||
PHP_5_1 This branch is closed.
|
||||
PHP_4_4 Is used to release the PHP 4.4.x series. Only bugfixes are permitted
|
||||
on this branch (Consult the releasemaster prior to commit).
|
||||
PHP_4_3 This branch is closed.
|
||||
@@ -100,9 +98,13 @@ For string.c:
|
||||
|
||||
The # lines will be omitted from the ChangeLog automagically.
|
||||
|
||||
Use the [DOC] tag in your log message whenever you feel that your changes
|
||||
imply a documentation modification. The php-doc team will automatically
|
||||
get notified about your commit through the php-doc mailing list.
|
||||
|
||||
If you fix some bugs, you should note the bug ID numbers in your
|
||||
commit message. Bug ID should be prefixed by "#" for easier access to
|
||||
bug report when developers are browsing CVS via. LXR or Bonsai.
|
||||
bug report when developers are browsing CVS via LXR or Bonsai.
|
||||
|
||||
Example:
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lsz",
|
||||
/* Gets an object of class specified by my_ce, and an optional double. */
|
||||
zval *obj;
|
||||
double d = 0.5;
|
||||
zend_class_entry my_ce;
|
||||
zend_class_entry *my_ce;
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O|d",
|
||||
&obj, my_ce, &d) == FAILURE) {
|
||||
return;
|
||||
|
||||
@@ -172,6 +172,21 @@ Items from the NEWS file explained
|
||||
from your error handler in order to populate $php_errormsg. This allows
|
||||
you to fine-grain the levels of the messages stored.
|
||||
|
||||
==============================
|
||||
Regressions introduced/fixed
|
||||
==============================
|
||||
|
||||
- In version 5.2.4 a security fix caused a regression for patterns of
|
||||
the form "/foo/*/bar/*". Since version 5.2.5 instead of raising a warning the
|
||||
glob() function will return false when openbase_dir restrictions are violated.
|
||||
|
||||
#See http://bugs.php.net/bug.php?id=41655
|
||||
|
||||
The warning that used to be raised looked like something as follows:
|
||||
Warning: glob() [function.glob]: Unable to access /foo/*/bar/* in /foo.php on line xxx
|
||||
#See http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dir.c?r1=1.169&r2=1.170
|
||||
|
||||
The patch can safely be applied to PHP 5.2.4 as well.
|
||||
|
||||
==============================
|
||||
Backwards incompatible changes
|
||||
|
||||
@@ -96,13 +96,6 @@ ext/pcntl
|
||||
* Remove all zend_extension code
|
||||
* Add object callback support to pcntl_signal()
|
||||
|
||||
ext/pgsql
|
||||
---------
|
||||
For PHP 4.3.0:
|
||||
* Add pg_metadata() with metadata cache feature.
|
||||
* Add pg_convert() to check and convert array value for query.
|
||||
* Add pg_insert/pg_update/pg_delete/pg_select for simple query.
|
||||
|
||||
ext/session
|
||||
-----------
|
||||
For PHP 4.3.0:
|
||||
|
||||
+135
-61
@@ -136,7 +136,7 @@ static int php_check_dots(const char *element, int n)
|
||||
free((s)->cwd);
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
CWD_API int php_sys_stat(const char *path, struct stat *buf)
|
||||
CWD_API int php_sys_stat(const char *path, struct stat *buf) /* {{{ */
|
||||
{
|
||||
WIN32_FILE_ATTRIBUTE_DATA data;
|
||||
__int64 t;
|
||||
@@ -215,9 +215,10 @@ CWD_API int php_sys_stat(const char *path, struct stat *buf)
|
||||
buf->st_mtime = (unsigned long)((t / 10000000) - 11644473600);
|
||||
return 0;
|
||||
}
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
static int php_is_dir_ok(const cwd_state *state)
|
||||
static int php_is_dir_ok(const cwd_state *state) /* {{{ */
|
||||
{
|
||||
struct stat buf;
|
||||
|
||||
@@ -226,8 +227,9 @@ static int php_is_dir_ok(const cwd_state *state)
|
||||
|
||||
return (1);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static int php_is_file_ok(const cwd_state *state)
|
||||
static int php_is_file_ok(const cwd_state *state) /* {{{ */
|
||||
{
|
||||
struct stat buf;
|
||||
|
||||
@@ -236,8 +238,9 @@ static int php_is_file_ok(const cwd_state *state)
|
||||
|
||||
return (1);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static void cwd_globals_ctor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
static void cwd_globals_ctor(virtual_cwd_globals *cwd_globals TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
CWD_STATE_COPY(&cwd_globals->cwd, &main_cwd_state);
|
||||
cwd_globals->realpath_cache_size = 0;
|
||||
@@ -245,14 +248,16 @@ static void cwd_globals_ctor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
cwd_globals->realpath_cache_ttl = REALPATH_CACHE_TTL;
|
||||
memset(cwd_globals->realpath_cache, 0, sizeof(cwd_globals->realpath_cache));
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static void cwd_globals_dtor(virtual_cwd_globals *cwd_globals TSRMLS_DC)
|
||||
static void cwd_globals_dtor(virtual_cwd_globals *cwd_globals TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
CWD_STATE_FREE(&cwd_globals->cwd);
|
||||
realpath_cache_clean(TSRMLS_C);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static char *tsrm_strndup(const char *s, size_t length)
|
||||
static char *tsrm_strndup(const char *s, size_t length) /* {{{ */
|
||||
{
|
||||
char *p;
|
||||
|
||||
@@ -266,8 +271,9 @@ static char *tsrm_strndup(const char *s, size_t length)
|
||||
p[length]=0;
|
||||
return p;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API void virtual_cwd_startup(void)
|
||||
CWD_API void virtual_cwd_startup(void) /* {{{ */
|
||||
{
|
||||
char cwd[MAXPATHLEN];
|
||||
char *result;
|
||||
@@ -302,8 +308,9 @@ CWD_API void virtual_cwd_startup(void)
|
||||
cwd_mutex = tsrm_mutex_alloc();
|
||||
#endif
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API void virtual_cwd_shutdown(void)
|
||||
CWD_API void virtual_cwd_shutdown(void) /* {{{ */
|
||||
{
|
||||
#ifndef ZTS
|
||||
cwd_globals_dtor(&cwd_globals TSRMLS_CC);
|
||||
@@ -314,8 +321,9 @@ CWD_API void virtual_cwd_shutdown(void)
|
||||
|
||||
free(main_cwd_state.cwd); /* Don't use CWD_STATE_FREE because the non global states will probably use emalloc()/efree() */
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API char *virtual_getcwd_ex(size_t *length TSRMLS_DC)
|
||||
CWD_API char *virtual_getcwd_ex(size_t *length TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state *state;
|
||||
|
||||
@@ -347,10 +355,10 @@ CWD_API char *virtual_getcwd_ex(size_t *length TSRMLS_DC)
|
||||
*length = state->cwd_length;
|
||||
return strdup(state->cwd);
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
|
||||
/* Same semantics as UNIX getcwd() */
|
||||
CWD_API char *virtual_getcwd(char *buf, size_t size TSRMLS_DC)
|
||||
CWD_API char *virtual_getcwd(char *buf, size_t size TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
size_t length;
|
||||
char *cwd;
|
||||
@@ -369,8 +377,9 @@ CWD_API char *virtual_getcwd(char *buf, size_t size TSRMLS_DC)
|
||||
free(cwd);
|
||||
return buf;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static inline unsigned long realpath_cache_key(const char *path, int path_len)
|
||||
static inline unsigned long realpath_cache_key(const char *path, int path_len) /* {{{ */
|
||||
{
|
||||
register unsigned long h;
|
||||
const char *e = path + path_len;
|
||||
@@ -382,8 +391,9 @@ static inline unsigned long realpath_cache_key(const char *path, int path_len)
|
||||
|
||||
return h;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API void realpath_cache_clean(TSRMLS_D)
|
||||
CWD_API void realpath_cache_clean(TSRMLS_D) /* {{{ */
|
||||
{
|
||||
int i;
|
||||
|
||||
@@ -398,8 +408,9 @@ CWD_API void realpath_cache_clean(TSRMLS_D)
|
||||
}
|
||||
CWDG(realpath_cache_size) = 0;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC)
|
||||
CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
unsigned long key = realpath_cache_key(path, path_len);
|
||||
unsigned long n = key % (sizeof(CWDG(realpath_cache)) / sizeof(CWDG(realpath_cache)[0]));
|
||||
@@ -418,8 +429,9 @@ CWD_API void realpath_cache_del(const char *path, int path_len TSRMLS_DC)
|
||||
}
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static inline void realpath_cache_add(const char *path, int path_len, const char *realpath, int realpath_len, time_t t TSRMLS_DC)
|
||||
static inline void realpath_cache_add(const char *path, int path_len, const char *realpath, int realpath_len, time_t t TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
long size = sizeof(realpath_cache_bucket) + path_len + 1 + realpath_len + 1;
|
||||
if (CWDG(realpath_cache_size) + size <= CWDG(realpath_cache_size_limit)) {
|
||||
@@ -440,8 +452,9 @@ static inline void realpath_cache_add(const char *path, int path_len, const char
|
||||
CWDG(realpath_cache_size) += size;
|
||||
}
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
static inline realpath_cache_bucket* realpath_cache_find(const char *path, int path_len, time_t t TSRMLS_DC)
|
||||
static inline realpath_cache_bucket* realpath_cache_find(const char *path, int path_len, time_t t TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
unsigned long key = realpath_cache_key(path, path_len);
|
||||
unsigned long n = key % (sizeof(CWDG(realpath_cache)) / sizeof(CWDG(realpath_cache)[0]));
|
||||
@@ -462,11 +475,11 @@ static inline realpath_cache_bucket* realpath_cache_find(const char *path, int p
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
|
||||
/* Resolve path relatively to state and put the real path into state */
|
||||
/* returns 0 for ok, 1 for error */
|
||||
CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func verify_path, int use_realpath)
|
||||
CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func verify_path, int use_realpath) /* {{{ */
|
||||
{
|
||||
int path_length = strlen(path);
|
||||
cwd_state old_state;
|
||||
@@ -476,12 +489,15 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
int ret;
|
||||
int use_cache;
|
||||
int use_relative_path = 0;
|
||||
#ifdef TSRM_WIN32
|
||||
int is_unc;
|
||||
#endif
|
||||
TSRMLS_FETCH();
|
||||
|
||||
|
||||
use_cache = ((use_realpath != CWD_EXPAND) && CWDG(realpath_cache_size_limit));
|
||||
|
||||
if (path_length == 0)
|
||||
return (0);
|
||||
return (1);
|
||||
if (path_length >= MAXPATHLEN)
|
||||
return (1);
|
||||
|
||||
@@ -518,7 +534,7 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
}
|
||||
|
||||
if (use_cache) {
|
||||
t = CWDG(realpath_cache_ttl)?time(NULL):0;
|
||||
t = CWDG(realpath_cache_ttl)?time(0):0;
|
||||
if ((bucket = realpath_cache_find(path, path_length, t TSRMLS_CC)) != NULL) {
|
||||
int len = bucket->realpath_len;
|
||||
|
||||
@@ -547,6 +563,7 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
}
|
||||
goto no_realpath;
|
||||
}
|
||||
use_realpath = CWD_REALPATH;
|
||||
CWD_STATE_COPY(&old_state, state);
|
||||
|
||||
state->cwd_length = strlen(resolved_path);
|
||||
@@ -559,11 +576,15 @@ CWD_API int virtual_file_ex(cwd_state *state, const char *path, verify_path_func
|
||||
char *ptr, *path_copy, *free_path;
|
||||
char *tok;
|
||||
int ptr_length;
|
||||
#ifdef TSRM_WIN32
|
||||
int is_unc;
|
||||
#endif
|
||||
no_realpath:
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
if (memchr(path, '*', path_length) ||
|
||||
memchr(path, '?', path_length)) {
|
||||
return 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
free_path = path_copy = tsrm_strndup(path, path_length);
|
||||
CWD_STATE_COPY(&old_state, state);
|
||||
|
||||
@@ -691,6 +712,15 @@ no_realpath:
|
||||
}
|
||||
ptr = tsrm_strtok_r(NULL, TOKENIZER_STRING, &tok);
|
||||
}
|
||||
#if defined(TSRM_WIN32) || defined(NETWARE)
|
||||
if (path[path_length-1] == '\\' || path[path_length-1] == '/') {
|
||||
#else
|
||||
if (path[path_length-1] == '/') {
|
||||
#endif
|
||||
state->cwd = (char*)realloc(state->cwd, state->cwd_length + 2);
|
||||
state->cwd[state->cwd_length++] = DEFAULT_SLASH;
|
||||
state->cwd[state->cwd_length] = 0;
|
||||
}
|
||||
|
||||
free(free_path);
|
||||
|
||||
@@ -708,7 +738,12 @@ no_realpath:
|
||||
}
|
||||
}
|
||||
|
||||
if (use_cache) {
|
||||
/* Store existent file in realpath cache. */
|
||||
#ifdef TSRM_WIN32
|
||||
if (use_cache && !is_unc) {
|
||||
#else
|
||||
if (use_cache && (use_realpath == CWD_REALPATH)) {
|
||||
#endif
|
||||
realpath_cache_add(path, path_length, state->cwd, state->cwd_length, t TSRMLS_CC);
|
||||
}
|
||||
|
||||
@@ -726,13 +761,15 @@ no_realpath:
|
||||
#endif
|
||||
return (ret);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_chdir(const char *path TSRMLS_DC)
|
||||
CWD_API int virtual_chdir(const char *path TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return virtual_file_ex(&CWDG(cwd), path, php_is_dir_ok, CWD_REALPATH)?-1:0;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_chdir_file(const char *path, int (*p_chdir)(const char *path TSRMLS_DC) TSRMLS_DC)
|
||||
CWD_API int virtual_chdir_file(const char *path, int (*p_chdir)(const char *path TSRMLS_DC) TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
int length = strlen(path);
|
||||
char *temp;
|
||||
@@ -763,13 +800,29 @@ CWD_API int virtual_chdir_file(const char *path, int (*p_chdir)(const char *path
|
||||
tsrm_free_alloca(temp);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API char *virtual_realpath(const char *path, char *real_path TSRMLS_DC)
|
||||
CWD_API char *virtual_realpath(const char *path, char *real_path TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
char *retval;
|
||||
char cwd[MAXPATHLEN];
|
||||
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
/* realpath("") returns CWD */
|
||||
if (!*path) {
|
||||
new_state.cwd = (char*)malloc(1);
|
||||
new_state.cwd[0] = '\0';
|
||||
new_state.cwd_length = 0;
|
||||
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
|
||||
path = cwd;
|
||||
}
|
||||
} else if (!IS_ABSOLUTE_PATH(path, strlen(path))) {
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
} else {
|
||||
new_state.cwd = (char*)malloc(1);
|
||||
new_state.cwd[0] = '\0';
|
||||
new_state.cwd_length = 0;
|
||||
}
|
||||
|
||||
if (virtual_file_ex(&new_state, path, NULL, CWD_REALPATH)==0) {
|
||||
int len = new_state.cwd_length>MAXPATHLEN-1?MAXPATHLEN-1:new_state.cwd_length;
|
||||
@@ -785,8 +838,9 @@ CWD_API char *virtual_realpath(const char *path, char *real_path TSRMLS_DC)
|
||||
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_filepath_ex(const char *path, char **filepath, verify_path_func verify_path TSRMLS_DC)
|
||||
CWD_API int virtual_filepath_ex(const char *path, char **filepath, verify_path_func verify_path TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
@@ -799,13 +853,15 @@ CWD_API int virtual_filepath_ex(const char *path, char **filepath, verify_path_f
|
||||
return retval;
|
||||
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_filepath(const char *path, char **filepath TSRMLS_DC)
|
||||
CWD_API int virtual_filepath(const char *path, char **filepath TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return virtual_filepath_ex(path, filepath, php_is_file_ok TSRMLS_CC);
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API FILE *virtual_fopen(const char *path, const char *mode TSRMLS_DC)
|
||||
CWD_API FILE *virtual_fopen(const char *path, const char *mode TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
FILE *f;
|
||||
@@ -825,8 +881,9 @@ CWD_API FILE *virtual_fopen(const char *path, const char *mode TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return f;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC)
|
||||
CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int ret;
|
||||
@@ -847,10 +904,10 @@ CWD_API int virtual_access(const char *pathname, int mode TSRMLS_DC)
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
|
||||
#if HAVE_UTIME
|
||||
CWD_API int virtual_utime(const char *filename, struct utimbuf *buf TSRMLS_DC)
|
||||
CWD_API int virtual_utime(const char *filename, struct utimbuf *buf TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int ret;
|
||||
@@ -866,9 +923,10 @@ CWD_API int virtual_utime(const char *filename, struct utimbuf *buf TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return ret;
|
||||
}
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC)
|
||||
CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int ret;
|
||||
@@ -884,9 +942,10 @@ CWD_API int virtual_chmod(const char *filename, mode_t mode TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return ret;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#if !defined(TSRM_WIN32) && !defined(NETWARE)
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int link TSRMLS_DC)
|
||||
CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int link TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int ret;
|
||||
@@ -910,9 +969,10 @@ CWD_API int virtual_chown(const char *filename, uid_t owner, gid_t group, int li
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return ret;
|
||||
}
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
CWD_API int virtual_open(const char *path TSRMLS_DC, int flags, ...)
|
||||
CWD_API int virtual_open(const char *path TSRMLS_DC, int flags, ...) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int f;
|
||||
@@ -938,8 +998,9 @@ CWD_API int virtual_open(const char *path TSRMLS_DC, int flags, ...)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return f;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_creat(const char *path, mode_t mode TSRMLS_DC)
|
||||
CWD_API int virtual_creat(const char *path, mode_t mode TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int f;
|
||||
@@ -955,22 +1016,23 @@ CWD_API int virtual_creat(const char *path, mode_t mode TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return f;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_rename(char *oldname, char *newname TSRMLS_DC)
|
||||
CWD_API int virtual_rename(char *oldname, char *newname TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state old_state;
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
|
||||
CWD_STATE_COPY(&old_state, &CWDG(cwd));
|
||||
if (virtual_file_ex(&old_state, oldname, NULL, CWD_REALPATH)) {
|
||||
if (virtual_file_ex(&old_state, oldname, NULL, CWD_EXPAND)) {
|
||||
CWD_STATE_FREE(&old_state);
|
||||
return -1;
|
||||
}
|
||||
oldname = old_state.cwd;
|
||||
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
if (virtual_file_ex(&new_state, newname, NULL, CWD_FILEPATH)) {
|
||||
if (virtual_file_ex(&new_state, newname, NULL, CWD_EXPAND)) {
|
||||
CWD_STATE_FREE(&old_state);
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return -1;
|
||||
@@ -984,8 +1046,9 @@ CWD_API int virtual_rename(char *oldname, char *newname TSRMLS_DC)
|
||||
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC)
|
||||
CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
@@ -1001,15 +1064,16 @@ CWD_API int virtual_stat(const char *path, struct stat *buf TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#if !defined(TSRM_WIN32)
|
||||
CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC)
|
||||
CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
|
||||
CWD_STATE_COPY(&new_state, &CWDG(cwd));
|
||||
if (virtual_file_ex(&new_state, path, NULL, CWD_REALPATH)) {
|
||||
if (virtual_file_ex(&new_state, path, NULL, CWD_EXPAND)) {
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return -1;
|
||||
}
|
||||
@@ -1019,9 +1083,10 @@ CWD_API int virtual_lstat(const char *path, struct stat *buf TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
CWD_API int virtual_unlink(const char *path TSRMLS_DC)
|
||||
CWD_API int virtual_unlink(const char *path TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
@@ -1037,8 +1102,9 @@ CWD_API int virtual_unlink(const char *path TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_mkdir(const char *pathname, mode_t mode TSRMLS_DC)
|
||||
CWD_API int virtual_mkdir(const char *pathname, mode_t mode TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
@@ -1057,8 +1123,9 @@ CWD_API int virtual_mkdir(const char *pathname, mode_t mode TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
CWD_API int virtual_rmdir(const char *pathname TSRMLS_DC)
|
||||
CWD_API int virtual_rmdir(const char *pathname TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
int retval;
|
||||
@@ -1074,12 +1141,13 @@ CWD_API int virtual_rmdir(const char *pathname TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
DIR *opendir(const char *name);
|
||||
#endif
|
||||
|
||||
CWD_API DIR *virtual_opendir(const char *pathname TSRMLS_DC)
|
||||
CWD_API DIR *virtual_opendir(const char *pathname TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
DIR *retval;
|
||||
@@ -1095,20 +1163,19 @@ CWD_API DIR *virtual_opendir(const char *pathname TSRMLS_DC)
|
||||
CWD_STATE_FREE(&new_state);
|
||||
return retval;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
#ifdef TSRM_WIN32
|
||||
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
return popen_ex(command, type, CWDG(cwd).cwd, NULL);
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
#elif defined(NETWARE)
|
||||
|
||||
/* On NetWare, the trick of prepending "cd cwd; " doesn't work so we need to perform
|
||||
a VCWD_CHDIR() and mutex it
|
||||
*/
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
char prev_cwd[MAXPATHLEN];
|
||||
char *getcwd_result;
|
||||
@@ -1133,10 +1200,9 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
#else /* Unix */
|
||||
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
int command_length;
|
||||
int dir_length, extra = 0;
|
||||
@@ -1193,15 +1259,23 @@ CWD_API FILE *virtual_popen(const char *command, const char *type TSRMLS_DC)
|
||||
free(command_line);
|
||||
return retval;
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
#endif
|
||||
|
||||
CWD_API char *tsrm_realpath(const char *path, char *real_path TSRMLS_DC)
|
||||
CWD_API char *tsrm_realpath(const char *path, char *real_path TSRMLS_DC) /* {{{ */
|
||||
{
|
||||
cwd_state new_state;
|
||||
char cwd[MAXPATHLEN];
|
||||
|
||||
if (!IS_ABSOLUTE_PATH(path, strlen(path)) &&
|
||||
/* realpath("") returns CWD */
|
||||
if (!*path) {
|
||||
new_state.cwd = (char*)malloc(1);
|
||||
new_state.cwd[0] = '\0';
|
||||
new_state.cwd_length = 0;
|
||||
if (VCWD_GETCWD(cwd, MAXPATHLEN)) {
|
||||
path = cwd;
|
||||
}
|
||||
} else if (!IS_ABSOLUTE_PATH(path, strlen(path)) &&
|
||||
VCWD_GETCWD(cwd, MAXPATHLEN)) {
|
||||
new_state.cwd = strdup(cwd);
|
||||
new_state.cwd_length = strlen(cwd);
|
||||
@@ -1226,7 +1300,7 @@ CWD_API char *tsrm_realpath(const char *path, char *real_path TSRMLS_DC)
|
||||
return new_state.cwd;
|
||||
}
|
||||
}
|
||||
|
||||
/* }}} */
|
||||
|
||||
/*
|
||||
* Local variables:
|
||||
|
||||
+28
-7
@@ -1,13 +1,34 @@
|
||||
The goal of the new memory manager (PHP 5.2 and later) is reducing memory allocation overhead and speedup memory management.
|
||||
Zend Memory Manager
|
||||
===================
|
||||
|
||||
The new manager's "configure" has no "--disable-zend-memory-manager" option, but it has "--enable-malloc-mm" instead. It is enabled by default in DEBUG build and disabled by default in RELEASE built. It allows select malloc/emalloc at runtime. So you can use internal and external memory debuggers without recompilation.
|
||||
General:
|
||||
--------
|
||||
|
||||
$ sapi/cli/php -r 'leak();'
|
||||
The goal of the new memory manager (available since PHP 5.2) is to reduce memory
|
||||
allocation overhead and speedup memory management.
|
||||
|
||||
$ USE_ZEND_ALLOC=0 valgrind --leak-check=full -r 'leak();'
|
||||
The new manager's "configure" has no "--disable-zend-memory-manager" option,
|
||||
but it has "--enable-malloc-mm" instead. It is enabled by default in DEBUG
|
||||
build and disabled by default in RELEASE build. when enabled it allows selecting
|
||||
between malloc and emalloc at runtime so you can use internal and external memory
|
||||
debuggers without recompilation.
|
||||
|
||||
The patch allows tweaking memory manager with ZEND_MM_MEM_TYPE and ZEND_MM_SEG_SIZE environment variables. Default values are "malloc" and "256K". Dependent on target system you can also use "mmap_anon", "mmap_zero"
|
||||
and "win32" storage managers.
|
||||
Debugging:
|
||||
----------
|
||||
|
||||
$ ZEND_MM_MEM_TYPE=mmap_anon ZEND_MM_SEG_SIZE=1M sapi/cli/php
|
||||
Normal:
|
||||
|
||||
$ sapi/cli/php -r 'leak();'
|
||||
|
||||
Zend MM disabled:
|
||||
|
||||
$ USE_ZEND_ALLOC=0 valgrind --leak-check=full sapi/cli/php -r 'leak();'
|
||||
|
||||
Tweaking:
|
||||
---------
|
||||
|
||||
The Zend MM can be tweaked using ZEND_MM_MEM_TYPE and ZEND_MM_SEG_SIZE environment
|
||||
variables. Default values are "malloc" and "256K". Dependent on target system you
|
||||
can also use "mmap_anon", "mmap_zero" and "win32" storage managers.
|
||||
|
||||
$ ZEND_MM_MEM_TYPE=mmap_anon ZEND_MM_SEG_SIZE=1M sapi/cli/php ..etc.
|
||||
+8
-4
@@ -10,9 +10,11 @@ var_dump(get_resource_type($fp));
|
||||
fclose($fp);
|
||||
var_dump(get_resource_type($fp));
|
||||
|
||||
var_dump(get_loaded_extensions(true));
|
||||
var_dump(gettype(get_loaded_extensions()));
|
||||
var_dump(count(get_loaded_extensions()));
|
||||
var_dump(gettype(get_loaded_extensions(true)));
|
||||
var_dump(count(get_loaded_extensions(true)));
|
||||
var_dump(get_loaded_extensions(true, true));
|
||||
|
||||
define("USER_CONSTANT", "test");
|
||||
|
||||
@@ -50,11 +52,13 @@ Warning: Supplied argument is not a valid resource handle in %s on line %d
|
||||
bool(false)
|
||||
string(6) "stream"
|
||||
string(7) "Unknown"
|
||||
|
||||
Warning: Wrong parameter count for get_loaded_extensions() in %s on line %d
|
||||
NULL
|
||||
string(5) "array"
|
||||
int(%d)
|
||||
string(5) "array"
|
||||
int(%d)
|
||||
|
||||
Warning: get_loaded_extensions() expects at most 1 parameter, 2 given in %s on line %d
|
||||
NULL
|
||||
|
||||
Warning: Wrong parameter count for get_defined_constants() in %s on line %d
|
||||
NULL
|
||||
|
||||
+1332
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,31 @@
|
||||
--TEST--
|
||||
func_get_arg() invalid usage
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
var_dump(func_get_arg(1,2,3));
|
||||
var_dump(func_get_arg(1));
|
||||
var_dump(func_get_arg());
|
||||
|
||||
function bar() {
|
||||
var_dump(func_get_arg(1));
|
||||
}
|
||||
|
||||
function foo() {
|
||||
bar(func_get_arg(1));
|
||||
}
|
||||
|
||||
foo(1,2);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
bool(false)
|
||||
|
||||
Warning: func_get_arg(): Called from the global scope - no function context in %s on line %d
|
||||
bool(false)
|
||||
bool(false)
|
||||
|
||||
Warning: func_get_arg(): Argument 1 not passed to function in %s on line %d
|
||||
bool(false)
|
||||
Done
|
||||
@@ -0,0 +1,73 @@
|
||||
--TEST--
|
||||
adding arrays
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(1,2,3);
|
||||
$b = array("str", "here");
|
||||
|
||||
$c = $a + $b;
|
||||
var_dump($c);
|
||||
|
||||
$a = array(1,2,3);
|
||||
$b = array(1,2,4);
|
||||
|
||||
$c = $a + $b;
|
||||
var_dump($c);
|
||||
|
||||
$a = array("a"=>"aaa",2,3);
|
||||
$b = array(1,2,"a"=>"bbbbbb");
|
||||
|
||||
$c = $a + $b;
|
||||
var_dump($c);
|
||||
|
||||
$a += $b;
|
||||
var_dump($c);
|
||||
|
||||
$a += $a;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(1)
|
||||
[1]=>
|
||||
int(2)
|
||||
[2]=>
|
||||
int(3)
|
||||
}
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(1)
|
||||
[1]=>
|
||||
int(2)
|
||||
[2]=>
|
||||
int(3)
|
||||
}
|
||||
array(3) {
|
||||
["a"]=>
|
||||
string(3) "aaa"
|
||||
[0]=>
|
||||
int(2)
|
||||
[1]=>
|
||||
int(3)
|
||||
}
|
||||
array(3) {
|
||||
["a"]=>
|
||||
string(3) "aaa"
|
||||
[0]=>
|
||||
int(2)
|
||||
[1]=>
|
||||
int(3)
|
||||
}
|
||||
array(3) {
|
||||
["a"]=>
|
||||
string(3) "aaa"
|
||||
[0]=>
|
||||
int(2)
|
||||
[1]=>
|
||||
int(3)
|
||||
}
|
||||
Done
|
||||
@@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
adding objects to arrays
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(1,2,3);
|
||||
|
||||
$o = new stdclass;
|
||||
$o->prop = "value";
|
||||
|
||||
$c = $a + $o;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
|
||||
Fatal error: Unsupported operand types in %s on line %d
|
||||
@@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
adding arrays to objects
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(1,2,3);
|
||||
|
||||
$o = new stdclass;
|
||||
$o->prop = "value";
|
||||
|
||||
$c = $o + $a;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
|
||||
Fatal error: Unsupported operand types in %s on line %d
|
||||
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
adding numbers to arrays
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(1,2,3);
|
||||
|
||||
$c = $a + 5;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Unsupported operand types in %s on line %d
|
||||
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
adding integers to doubles
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$i = 75636;
|
||||
$d = 2834681123.123123;
|
||||
|
||||
$c = $i + $d;
|
||||
var_dump($c);
|
||||
|
||||
$c = $d + $i;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
float(2834756759.1231)
|
||||
float(2834756759.1231)
|
||||
Done
|
||||
@@ -0,0 +1,49 @@
|
||||
--TEST--
|
||||
adding numbers to strings
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$i = 75636;
|
||||
$s1 = "this is a string";
|
||||
$s2 = "876222numeric";
|
||||
$s3 = "48474874";
|
||||
$s4 = "25.68";
|
||||
|
||||
$c = $i + $s1;
|
||||
var_dump($c);
|
||||
|
||||
$c = $i + $s2;
|
||||
var_dump($c);
|
||||
|
||||
$c = $i + $s3;
|
||||
var_dump($c);
|
||||
|
||||
$c = $i + $s4;
|
||||
var_dump($c);
|
||||
|
||||
$c = $s1 + $i;
|
||||
var_dump($c);
|
||||
|
||||
$c = $s2 + $i;
|
||||
var_dump($c);
|
||||
|
||||
$c = $s3 + $i;
|
||||
var_dump($c);
|
||||
|
||||
$c = $s4 + $i;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
int(75636)
|
||||
int(951858)
|
||||
int(48550510)
|
||||
float(75661.68)
|
||||
int(75636)
|
||||
int(951858)
|
||||
int(48550510)
|
||||
float(75661.68)
|
||||
Done
|
||||
@@ -0,0 +1,16 @@
|
||||
--TEST--
|
||||
adding strings to arrays
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(1,2,3);
|
||||
|
||||
$s1 = "some string";
|
||||
|
||||
$c = $a + $s1;
|
||||
var_dump($c);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Unsupported operand types in %s on line %d
|
||||
@@ -0,0 +1,39 @@
|
||||
--TEST--
|
||||
bitwise AND and strings
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$s = "123";
|
||||
$s1 = "234";
|
||||
|
||||
var_dump($s & $s1);
|
||||
|
||||
$s = "test";
|
||||
$s1 = "some";
|
||||
|
||||
var_dump($s & $s1);
|
||||
|
||||
$s = "test long";
|
||||
$s1 = "some";
|
||||
|
||||
var_dump($s & $s1);
|
||||
|
||||
$s = "test";
|
||||
$s1 = "some long";
|
||||
|
||||
var_dump($s & $s1);
|
||||
|
||||
$s = "test";
|
||||
$s &= "some long";
|
||||
|
||||
var_dump($s);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(3) "020"
|
||||
string(4) "pead"
|
||||
string(4) "pead"
|
||||
string(4) "pead"
|
||||
string(4) "pead"
|
||||
Done
|
||||
@@ -0,0 +1,16 @@
|
||||
--TEST--
|
||||
Tests that array manipulation code is correctly dealing with copy on write and splitting on reference
|
||||
--FILE--
|
||||
<?php
|
||||
$a=array();
|
||||
$b=1;
|
||||
$c=&$b;
|
||||
$a[]=$b;
|
||||
$b=2;
|
||||
var_dump ($a);
|
||||
?>
|
||||
--EXPECT--
|
||||
array(1) {
|
||||
[0]=>
|
||||
int(1)
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
--TEST--
|
||||
Tests that array unshift code is correctly dealing with copy on write and splitting on reference
|
||||
--FILE--
|
||||
<?php
|
||||
$a=array();
|
||||
$b=1;
|
||||
$c=&$b;
|
||||
array_unshift ($a,$b);
|
||||
$b=2;
|
||||
var_dump ($a);
|
||||
?>
|
||||
--EXPECT--
|
||||
array(1) {
|
||||
[0]=>
|
||||
int(1)
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
bug #22725 (A derived class can call a parent's protected method that calls a private method)
|
||||
Bug #22725 (A derived class can call a parent's protected method that calls a private method)
|
||||
--SKIPIF--
|
||||
<?php if (version_compare(zend_version(), '2.0.0-dev', '<')) die('skip ZendEngine 2 needed'); ?>
|
||||
--FILE--
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #27304
|
||||
Bug #27304 (Static functions don't function properly)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
||||
@@ -49,12 +49,12 @@ array(1) {
|
||||
}
|
||||
Base::__construct
|
||||
array(3) {
|
||||
["Baz"]=>
|
||||
int(4)
|
||||
["Foo"]=>
|
||||
int(1)
|
||||
["Bar"]=>
|
||||
int(2)
|
||||
["Baz"]=>
|
||||
int(3)
|
||||
}
|
||||
Child::__construct
|
||||
array(3) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #29104 Function declaration in method doesn't work
|
||||
Bug #29104 (Function declaration in method doesn't work)
|
||||
--FILE--
|
||||
<?php
|
||||
class A
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #29210 Function: is_callable - no support for private and protected classes
|
||||
Bug #29210 (Function is_callable does not support private and protected methods)
|
||||
--FILE--
|
||||
<?php
|
||||
class test_class {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #30519 Interface not existing says Class not found
|
||||
Bug #30519 (Interface not existing says Class not found)
|
||||
--FILE--
|
||||
<?php
|
||||
class test implements a {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #30702 cannot initialize class variable from class constant
|
||||
Bug #30702 (cannot initialize class variable from class constant)
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #30791 magic methods (__sleep/__wakeup/__toString) call __call if object is overloaded
|
||||
Bug #30791 (magic methods (__sleep/__wakeup/__toString) call __call if object is overloaded)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #30889 Conflict between __get/__set and ++ operator
|
||||
Bug #30889 (Conflict between __get/__set and ++ operator)
|
||||
--FILE--
|
||||
<?php
|
||||
class overloaded
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #32296 get_class_methods output has changed between 5.0.2 and 5.0.3
|
||||
Bug #32296 (get_class_methods output has changed between 5.0.2 and 5.0.3)
|
||||
--FILE--
|
||||
<?php
|
||||
abstract class space{
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #32427 Interfaces are not allowed 'static' access modifier
|
||||
Bug #32427 (Interfaces are not allowed 'static' access modifier)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #32660 Assignment by reference causes crash when field access is overloaded (__get)
|
||||
Bug #32660 (Assignment by reference causes crash when field access is overloaded (__get))
|
||||
--FILE--
|
||||
<?php
|
||||
class A
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #32674 exception in iterator causes crash
|
||||
Bug #32674 (exception in iterator causes crash)
|
||||
--FILE--
|
||||
<?php
|
||||
class collection implements Iterator {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #32833 Invalid opcode
|
||||
Bug #32833 (Invalid opcode with $a[] .= '')
|
||||
--FILE--
|
||||
<?php
|
||||
$test = array();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #33257 array_splice() inconsistent when passed function instead of variable
|
||||
Bug #33257 (array_splice() inconsistent when passed function instead of variable)
|
||||
--INI--
|
||||
error_reporting=4095
|
||||
--FILE--
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #34712 zend.ze1_compatibility_mode = on segfault
|
||||
Bug #34712 (zend.ze1_compatibility_mode = on segfault)
|
||||
--INI--
|
||||
zend.ze1_compatibility_mode=1
|
||||
error_reporting=4095
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #35437 Segfault or Invalid Opcode 137/1/4
|
||||
Bug #35437 (Segfault or Invalid Opcode 137/1/4)
|
||||
--FILE--
|
||||
<?php
|
||||
function err2exception($errno, $errstr)
|
||||
|
||||
@@ -6,8 +6,6 @@ error_reporting=4095
|
||||
<?php
|
||||
$a = clone 0;
|
||||
$a[0]->b = 0;
|
||||
echo "ok\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: __clone method called on non-object in %sbug36071.php on line 2
|
||||
ok
|
||||
Fatal error: __clone method called on non-object in %sbug36071.php on line 2
|
||||
Executable
+29
@@ -0,0 +1,29 @@
|
||||
--TEST--
|
||||
Bug #37715 (array pointers resetting on copy)
|
||||
--FILE--
|
||||
<?php
|
||||
$a = array(
|
||||
'a' => array(
|
||||
'A', 'B', 'C', 'D',
|
||||
),
|
||||
'b' => array(
|
||||
'AA', 'BB', 'CC', 'DD',
|
||||
),
|
||||
);
|
||||
|
||||
// Set the pointer of $a to 'b' and the pointer of 'b' to 'CC'
|
||||
reset($a);
|
||||
next($a);
|
||||
next($a['b']);
|
||||
next($a['b']);
|
||||
next($a['b']);
|
||||
|
||||
var_dump(key($a['b']));
|
||||
foreach($a as $k => $d)
|
||||
{
|
||||
}
|
||||
// Alternatively $c = $a; and foreachloop removal will cause identical results.
|
||||
var_dump(key($a['b']));
|
||||
--EXPECT--
|
||||
int(3)
|
||||
int(3)
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #37811 define not using toString on objects
|
||||
Bug #37811 (define not using toString on objects)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #38220 Crash on some object operations
|
||||
Bug #38220 (Crash on some object operations)
|
||||
--FILE--
|
||||
<?php
|
||||
class drv {
|
||||
|
||||
Executable
+24
@@ -0,0 +1,24 @@
|
||||
--TEST--
|
||||
Bug #39542 (Behaviour of require_once/include_once different to < 5.2.0)
|
||||
--FILE--
|
||||
<?php
|
||||
$oldcwd = getcwd();
|
||||
chdir(dirname(__FILE__));
|
||||
if (substr(PHP_OS, 0, 3) == 'WIN') {
|
||||
set_include_path(dirname(__FILE__).'/bug39542;.');
|
||||
} else {
|
||||
set_include_path(dirname(__FILE__).'/bug39542:.');
|
||||
}
|
||||
|
||||
function __autoload($class) {
|
||||
if (!require_once($class.'.php')) {
|
||||
error_log('Error: Autoload class: '.$class.' not found!');
|
||||
}
|
||||
}
|
||||
|
||||
new bug39542();
|
||||
|
||||
chdir($oldcwd);
|
||||
?>
|
||||
--EXPECT--
|
||||
ok
|
||||
Executable
+7
@@ -0,0 +1,7 @@
|
||||
<?php
|
||||
class bug39542 {
|
||||
function bug39542() {
|
||||
echo "ok\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -1,7 +1,10 @@
|
||||
--TEST--
|
||||
Bug #40236 (php -a function allocation eats memory)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (php_sapi_name() != "cli") die("skip CLI only");
|
||||
if (extension_loaded("readline")) die("skip Test doesn't support readline");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$php = getenv('TEST_PHP_EXECUTABLE');
|
||||
|
||||
Executable
+26
@@ -0,0 +1,26 @@
|
||||
--TEST--
|
||||
Bug #40509 (key() function changed behaviour if global array is used within function)
|
||||
--FILE--
|
||||
<?php
|
||||
function foo()
|
||||
{
|
||||
global $arr;
|
||||
|
||||
$c = $arr["v"];
|
||||
foreach ($c as $v) {}
|
||||
}
|
||||
|
||||
$arr["v"] = array("a");
|
||||
|
||||
var_dump(key($arr["v"]));
|
||||
foo();
|
||||
var_dump(key($arr["v"]));
|
||||
foreach ($arr["v"] as $k => $v) {
|
||||
var_dump($k);
|
||||
}
|
||||
var_dump(key($arr["v"]));
|
||||
--EXPECT--
|
||||
int(0)
|
||||
int(0)
|
||||
int(0)
|
||||
NULL
|
||||
Executable
+26
@@ -0,0 +1,26 @@
|
||||
--TEST--
|
||||
Bug #40705 (Iterating within function moves original array pointer)
|
||||
--FILE--
|
||||
<?php
|
||||
function doForeach($array)
|
||||
{
|
||||
foreach ($array as $k => $v) {
|
||||
// do stuff
|
||||
}
|
||||
}
|
||||
|
||||
$foo = array('foo', 'bar', 'baz');
|
||||
var_dump(key($foo));
|
||||
doForeach($foo);
|
||||
var_dump(key($foo));
|
||||
foreach ($foo as $k => $v) {
|
||||
var_dump($k);
|
||||
}
|
||||
var_dump(key($foo));
|
||||
--EXPECT--
|
||||
int(0)
|
||||
int(0)
|
||||
int(0)
|
||||
int(1)
|
||||
int(2)
|
||||
NULL
|
||||
Executable
+28
@@ -0,0 +1,28 @@
|
||||
--TEST--
|
||||
Bug #40757 (get_object_vars() get nothing in child class)
|
||||
--FILE--
|
||||
<?php
|
||||
class Base {
|
||||
private $p1='sadf';
|
||||
|
||||
function getFields($obj){
|
||||
return get_object_vars($obj);
|
||||
}
|
||||
}
|
||||
|
||||
class Child extends Base { }
|
||||
|
||||
$base=new Base();
|
||||
print_r($base->getFields(new Base()));
|
||||
$child=new Child();
|
||||
print_r($child->getFields(new Base()));
|
||||
?>
|
||||
--EXPECT--
|
||||
Array
|
||||
(
|
||||
[p1] => sadf
|
||||
)
|
||||
Array
|
||||
(
|
||||
[p1] => sadf
|
||||
)
|
||||
@@ -1,7 +1,14 @@
|
||||
--TEST--
|
||||
Bug #40770 Apache child exits when PHP memory limit reached
|
||||
Bug #40770 (Apache child exits when PHP memory limit reached)
|
||||
--INI--
|
||||
memory_limit=8M
|
||||
--SKIPIF--
|
||||
<?php
|
||||
$zend_mm_enabled = getenv("USE_ZEND_ALLOC");
|
||||
if ($zend_mm_enabled === "0") {
|
||||
die("skip Zend MM disabled");
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
ini_set('display_errors',true);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #40809 Poor perfomance of ".="
|
||||
Bug #40809 (Poor perfomance of ".=")
|
||||
--FILE--
|
||||
<?php
|
||||
error_reporting(E_ALL|E_STRICT);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Bug #41075(memleak when creating default object caused exception)
|
||||
Bug #41075 (memleak when creating default object caused exception)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
||||
Executable
+14
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #41117 (Altering $this via argument)
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {
|
||||
function __construct($this) {
|
||||
echo $this."\n";
|
||||
}
|
||||
}
|
||||
$obj = new foo("Hello world");
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot re-assign $this in %sbug41117_1.php on line 3
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
--TEST--
|
||||
Bug #41209 (Segmentation fault with ArrayAccess, set_error_handler and undefined var)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class env
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
set_error_handler(array(__CLASS__, 'errorHandler'));
|
||||
}
|
||||
|
||||
public static function errorHandler($errno, $errstr, $errfile, $errline)
|
||||
{
|
||||
throw new ErrorException($errstr, 0, $errno, $errfile, $errline);
|
||||
}
|
||||
}
|
||||
|
||||
class cache implements ArrayAccess
|
||||
{
|
||||
private $container = array();
|
||||
|
||||
public function offsetGet($id) {}
|
||||
|
||||
public function offsetSet($id, $value) {}
|
||||
|
||||
public function offsetUnset($id) {}
|
||||
|
||||
public function offsetExists($id)
|
||||
{
|
||||
return isset($this->containers[(string) $id]);
|
||||
}
|
||||
}
|
||||
|
||||
$env = new env();
|
||||
$cache = new cache();
|
||||
var_dump(isset($cache[$id]));
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Uncaught exception 'ErrorException' with message 'Undefined variable: id' in %s:%d
|
||||
Stack trace:
|
||||
#0 %s(%d): env::errorHandler()
|
||||
#1 {main}
|
||||
thrown in %s on line %d
|
||||
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #41351 (Invalid opcode with foreach ($a[] as $b))
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array();
|
||||
|
||||
foreach($a[] as $b) {
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot use [] for reading in %s on line %d
|
||||
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #41351 (Invalid opcode with foreach ($a[] as $b)) - 2
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array();
|
||||
|
||||
foreach($a[]['test'] as $b) {
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot use [] for reading in %s on line %d
|
||||
@@ -0,0 +1,14 @@
|
||||
--TEST--
|
||||
Bug #41351 (Invalid opcode with foreach ($a[] as $b)) - 3
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array();
|
||||
|
||||
foreach($a['test'][] as $b) {
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot use [] for reading in %s on line %d
|
||||
Executable
+13
@@ -0,0 +1,13 @@
|
||||
--TEST--
|
||||
Bug #41372 Internal pointer of source array resets during array copying
|
||||
--FILE--
|
||||
<?php
|
||||
$Foo = array('val1', 'val2', 'val3');
|
||||
end($Foo);
|
||||
echo key($Foo),"\n";
|
||||
$MagicInternalPointerResetter = $Foo;
|
||||
echo key($Foo),"\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
2
|
||||
2
|
||||
Executable
+10
@@ -0,0 +1,10 @@
|
||||
--TEST--
|
||||
Bug #41401 (wrong precedence for unary minus)
|
||||
--FILE--
|
||||
<?php
|
||||
echo 1/-2*5;
|
||||
echo "\n";
|
||||
echo 6/+2*-3;
|
||||
--EXPECT--
|
||||
-2.5
|
||||
-9
|
||||
@@ -0,0 +1,29 @@
|
||||
--TEST--
|
||||
Bug #41421 (Uncaught exception from a stream wrapper segfaults)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class wrapper {
|
||||
function stream_open() {
|
||||
return true;
|
||||
}
|
||||
function stream_eof() {
|
||||
throw new exception();
|
||||
}
|
||||
}
|
||||
|
||||
stream_wrapper_register("wrap", "wrapper");
|
||||
$fp = fopen("wrap://...", "r");
|
||||
feof($fp);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: feof(): wrapper::stream_eof is not implemented! Assuming EOF in %s on line %d
|
||||
|
||||
Fatal error: Uncaught exception 'Exception' in %s:%d
|
||||
Stack trace:
|
||||
#0 [internal function]: wrapper->stream_eof()
|
||||
#1 %s(%d): feof(Resource id #6)
|
||||
#2 {main}
|
||||
thrown in %s on line %d
|
||||
Executable
+12
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #41633.1 (self:: doesn't work for constants)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
const A = self::B;
|
||||
const B = "ok";
|
||||
}
|
||||
echo Foo::A."\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
ok
|
||||
Executable
+11
@@ -0,0 +1,11 @@
|
||||
--TEST--
|
||||
Bug #41633.2 (Undefined class constants must not be substituted by strings)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
const A = self::B;
|
||||
}
|
||||
echo Foo::A."\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Undefined class constant 'self::B' in %sbug41633_2.php on line 5
|
||||
Executable
+12
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #41633.3 (Crash instantiating classes with self-referencing constants)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
const A = Foo::B;
|
||||
const B = Foo::A;
|
||||
}
|
||||
echo Foo::A;
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot declare self-referencing constant 'Foo::B' in %sbug41633_3.php on line %d
|
||||
Executable
+12
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #41633.4 (self:: doesn't work for constants)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
const A = self::B;
|
||||
const B = "ok";
|
||||
}
|
||||
var_dump(defined("Foo::A"));
|
||||
?>
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
@@ -0,0 +1,15 @@
|
||||
--TEST--
|
||||
Bug #41640 (get_class_vars produces error on class constants)
|
||||
--FILE--
|
||||
<?php
|
||||
class foo {
|
||||
const FOO = 1;
|
||||
public $x = self::FOO;
|
||||
}
|
||||
|
||||
var_dump(get_class_vars("foo"));
|
||||
--EXPECT--
|
||||
array(1) {
|
||||
["x"]=>
|
||||
int(1)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #41813 (segmentation fault when using string offset as an object)
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$foo = "50";
|
||||
$foo[0]->bar = "xyz";
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Cannot use string offset as an array in %s on line %d
|
||||
@@ -0,0 +1,12 @@
|
||||
--TEST--
|
||||
Bug #41919 (crash in string to array conversion)
|
||||
--FILE--
|
||||
<?php
|
||||
$foo="50";
|
||||
$foo[3]->bar[1] = "bang";
|
||||
|
||||
echo "ok\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
Warning: Cannot use string offset as an array in %s/bug41919.php on line %d
|
||||
ok
|
||||
Executable
+24
@@ -0,0 +1,24 @@
|
||||
--TEST--
|
||||
Bug #41929 (Foreach on object does not iterate over all visible properties)
|
||||
--FILE--
|
||||
<?php
|
||||
class C {
|
||||
private $priv = "ok";
|
||||
|
||||
function doLoop() {
|
||||
echo $this->priv,"\n";
|
||||
foreach ($this as $k=>$v) {
|
||||
echo "$k: $v\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class D extends C {
|
||||
}
|
||||
|
||||
$myD = new D;
|
||||
$myD->doLoop();
|
||||
?>
|
||||
--EXPECT--
|
||||
ok
|
||||
priv: ok
|
||||
Executable
+29
@@ -0,0 +1,29 @@
|
||||
--TEST--
|
||||
Bug #41961 (Ensure search for hidden private methods does not stray from class hierarchy)
|
||||
--FILE--
|
||||
<?php
|
||||
X::test();
|
||||
|
||||
/** Class X is related to neither ParentClass nor ChildClass. */
|
||||
class X {
|
||||
public static function test() {
|
||||
$myChild = new ChildClass;
|
||||
$myChild->secret(); // bug - invokes X::secret() instead of ChildClass::secret()
|
||||
}
|
||||
private function secret() {
|
||||
echo "Called private " . __METHOD__ . "() on an instance of: " . get_class($this) . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
class ParentClass {
|
||||
private function secret() { }
|
||||
}
|
||||
|
||||
class ChildClass extends ParentClass {
|
||||
public function secret() {
|
||||
echo "Called public " . __METHOD__ . "() on an instance of: " . get_class($this) . "\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
--EXPECT--
|
||||
Called public ChildClass::secret() on an instance of: ChildClass
|
||||
Executable
+19
@@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
Bug #42119 (array_push($arr,&$obj) doesn't work with zend.ze1_compatibility_mode On)
|
||||
--INI--
|
||||
allow_call_time_pass_reference=1
|
||||
zend.ze1_compatibility_mode=1
|
||||
--FILE--
|
||||
<?php
|
||||
class myclass {
|
||||
var $item = 1;
|
||||
}
|
||||
|
||||
$arr = array();
|
||||
@$myobj = new myclass();
|
||||
array_push($arr,&$myobj);
|
||||
$myobj->item = 2;
|
||||
echo $arr[0]->item,"\n";
|
||||
?>
|
||||
--EXPECT--
|
||||
2
|
||||
@@ -0,0 +1,30 @@
|
||||
--TEST--
|
||||
Bug #42211 (property_exists() fails to find protected properties from a parent class)
|
||||
--FILE--
|
||||
<?php
|
||||
class A {
|
||||
function foo() {
|
||||
var_dump(property_exists('B', 'publicBar'));
|
||||
var_dump(property_exists('B', 'protectedBar'));
|
||||
var_dump(property_exists('B', 'privateBar'));
|
||||
}
|
||||
}
|
||||
|
||||
class B extends A {
|
||||
static public $publicBar = "ok";
|
||||
static protected $protectedBar = "ok";
|
||||
static private $privateBar = "fail";
|
||||
}
|
||||
|
||||
$a = new A();
|
||||
$a->foo();
|
||||
$b = new B();
|
||||
$b->foo();
|
||||
--EXPECT--
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(false)
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
--TEST--
|
||||
Bug #42767 (highlight_string() truncates trailing comments)
|
||||
--FILE--
|
||||
<?php
|
||||
highlight_string('<?php /*some comment..');
|
||||
?>
|
||||
--EXPECT--
|
||||
<code><span style="color: #000000">
|
||||
<span style="color: #0000BB"><?php </span><span style="color: #FF8000">/*some comment..</span>
|
||||
</span>
|
||||
</code>
|
||||
Executable
+18
@@ -0,0 +1,18 @@
|
||||
--TEST--
|
||||
Bug #42772 (Storing $this in a static var fails while handling a cast to string)
|
||||
--FILE--
|
||||
<?php
|
||||
class Foo {
|
||||
static public $foo;
|
||||
function __toString() {
|
||||
self::$foo = $this;
|
||||
return 'foo';
|
||||
}
|
||||
}
|
||||
|
||||
$foo = (string)new Foo();
|
||||
var_dump(Foo::$foo);
|
||||
?>
|
||||
--EXPECT--
|
||||
object(Foo)#1 (0) {
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
--TEST--
|
||||
Bug #42817 (clone() on a non-object does not result in a fatal error)
|
||||
--FILE--
|
||||
<?php
|
||||
$a = clone(null);
|
||||
array_push($a->b, $c);
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: __clone method called on non-object in %sbug42817.php on line 2
|
||||
@@ -0,0 +1,9 @@
|
||||
--TEST--
|
||||
Bug #42818 ($foo = clone(array()); leaks memory)
|
||||
--FILE--
|
||||
<?php
|
||||
$foo = clone(array());
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: __clone method called on non-object in %sbug42818.php on line 2
|
||||
|
||||
Binary file not shown.
@@ -0,0 +1,53 @@
|
||||
--TEST--
|
||||
casting different variables to boolean
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$r = fopen(__FILE__, "r");
|
||||
|
||||
class test {
|
||||
function __toString() {
|
||||
return "10";
|
||||
}
|
||||
}
|
||||
|
||||
$o = new test;
|
||||
|
||||
$vars = array(
|
||||
"string",
|
||||
"8754456",
|
||||
"",
|
||||
"\0",
|
||||
9876545,
|
||||
0.10,
|
||||
array(),
|
||||
array(1,2,3),
|
||||
false,
|
||||
true,
|
||||
NULL,
|
||||
$r,
|
||||
$o
|
||||
);
|
||||
|
||||
foreach ($vars as $var) {
|
||||
$tmp = (bool)$var;
|
||||
var_dump($tmp);
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(false)
|
||||
bool(true)
|
||||
bool(true)
|
||||
Done
|
||||
@@ -0,0 +1,57 @@
|
||||
--TEST--
|
||||
casting different variables to double
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$r = fopen(__FILE__, "r");
|
||||
|
||||
class test {
|
||||
function __toString() {
|
||||
return "10";
|
||||
}
|
||||
}
|
||||
|
||||
$o = new test;
|
||||
|
||||
$vars = array(
|
||||
"string",
|
||||
"8754456",
|
||||
"",
|
||||
"\0",
|
||||
9876545,
|
||||
0.10,
|
||||
array(),
|
||||
array(1,2,3),
|
||||
false,
|
||||
true,
|
||||
NULL,
|
||||
$r,
|
||||
$o
|
||||
);
|
||||
|
||||
foreach ($vars as $var) {
|
||||
$tmp = (double)$var;
|
||||
var_dump($tmp);
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
float(0)
|
||||
float(8754456)
|
||||
float(0)
|
||||
float(0)
|
||||
float(9876545)
|
||||
float(0.1)
|
||||
float(0)
|
||||
float(1)
|
||||
float(0)
|
||||
float(1)
|
||||
float(0)
|
||||
float(%d)
|
||||
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
float(1)
|
||||
Done
|
||||
@@ -0,0 +1,55 @@
|
||||
--TEST--
|
||||
casting different variables to integer
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$r = fopen(__FILE__, "r");
|
||||
|
||||
class test {
|
||||
function __toString() {
|
||||
return "10";
|
||||
}
|
||||
}
|
||||
|
||||
$o = new test;
|
||||
|
||||
$vars = array(
|
||||
"string",
|
||||
"8754456",
|
||||
"",
|
||||
"\0",
|
||||
9876545,
|
||||
0.10,
|
||||
array(),
|
||||
array(1,2,3),
|
||||
false,
|
||||
true,
|
||||
NULL,
|
||||
$r,
|
||||
$o
|
||||
);
|
||||
|
||||
foreach ($vars as $var) {
|
||||
$tmp = (int)$var;
|
||||
var_dump($tmp);
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
int(0)
|
||||
int(8754456)
|
||||
int(0)
|
||||
int(0)
|
||||
int(9876545)
|
||||
int(0)
|
||||
int(0)
|
||||
int(1)
|
||||
int(0)
|
||||
int(1)
|
||||
int(0)
|
||||
int(%d)
|
||||
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
int(1)
|
||||
Done
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,22 @@
|
||||
--TEST--
|
||||
class constants basic tests
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
const val = "string";
|
||||
const val2 = 1;
|
||||
}
|
||||
|
||||
var_dump(test::val);
|
||||
var_dump(test::val2);
|
||||
|
||||
var_dump(test::val3);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(6) "string"
|
||||
int(1)
|
||||
|
||||
Fatal error: Undefined class constant 'val3' in %s on line %d
|
||||
@@ -0,0 +1,31 @@
|
||||
--TEST--
|
||||
class constants as default function arguments
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
const val = 1;
|
||||
}
|
||||
|
||||
function foo($v = test::val) {
|
||||
var_dump($v);
|
||||
}
|
||||
|
||||
function bar($b = NoSuchClass::val) {
|
||||
var_dump($b);
|
||||
}
|
||||
|
||||
foo();
|
||||
foo(5);
|
||||
|
||||
bar(10);
|
||||
bar();
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
int(1)
|
||||
int(5)
|
||||
int(10)
|
||||
|
||||
Fatal error: Class 'NoSuchClass' not found in %s on line %d
|
||||
@@ -0,0 +1,33 @@
|
||||
--TEST--
|
||||
class constants as default function arguments and dynamically loaded classes
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$class_data = <<<DATA
|
||||
<?php
|
||||
class test {
|
||||
const val = 1;
|
||||
}
|
||||
?>
|
||||
DATA;
|
||||
|
||||
$filename = dirname(__FILE__)."/cc003.dat";
|
||||
file_put_contents($filename, $class_data);
|
||||
|
||||
function foo($v = test::val) {
|
||||
var_dump($v);
|
||||
}
|
||||
|
||||
include $filename;
|
||||
|
||||
foo();
|
||||
foo(5);
|
||||
|
||||
unlink($filename);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
int(1)
|
||||
int(5)
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables for equality
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var == $a[$i]) ? " == " : " != ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} == array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} == bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(11) "-2147483648"
|
||||
string(0) "" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" == string(0) ""
|
||||
string(0) "" != int(1)
|
||||
string(0) "" != float(2.5)
|
||||
string(0) "" == int(0)
|
||||
string(0) "" != string(6) "string"
|
||||
string(0) "" != string(3) "123"
|
||||
string(0) "" != string(3) "2.5"
|
||||
string(0) "" == NULL
|
||||
string(0) "" != bool(true)
|
||||
string(0) "" == bool(false)
|
||||
string(0) "" != object(stdClass)#1 (0) {}
|
||||
string(0) "" != object(stdClass)#2 (0) {}
|
||||
string(0) "" != object(test)#3 (0) {}
|
||||
string(0) "" != array(0) {}
|
||||
string(0) "" != int(-2147483648)
|
||||
string(0) "" != string(11) "-2147483648"
|
||||
int(1) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) != string(0) ""
|
||||
int(1) == int(1)
|
||||
int(1) != float(2.5)
|
||||
int(1) != int(0)
|
||||
int(1) != string(6) "string"
|
||||
int(1) != string(3) "123"
|
||||
int(1) != string(3) "2.5"
|
||||
int(1) != NULL
|
||||
int(1) == bool(true)
|
||||
int(1) != bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== object(stdClass)#1 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== object(stdClass)#2 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
== object(test)#3 (0) {}
|
||||
int(1) != array(0) {}
|
||||
int(1) != int(-2147483648)
|
||||
int(1) != string(11) "-2147483648"
|
||||
float(2.5) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) != string(0) ""
|
||||
float(2.5) != int(1)
|
||||
float(2.5) == float(2.5)
|
||||
float(2.5) != int(0)
|
||||
float(2.5) != string(6) "string"
|
||||
float(2.5) != string(3) "123"
|
||||
float(2.5) == string(3) "2.5"
|
||||
float(2.5) != NULL
|
||||
float(2.5) == bool(true)
|
||||
float(2.5) != bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= object(stdClass)#1 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= object(stdClass)#2 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
!= object(test)#3 (0) {}
|
||||
float(2.5) != array(0) {}
|
||||
float(2.5) != int(-2147483648)
|
||||
float(2.5) != string(11) "-2147483648"
|
||||
int(0) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) == string(0) ""
|
||||
int(0) != int(1)
|
||||
int(0) != float(2.5)
|
||||
int(0) == int(0)
|
||||
int(0) == string(6) "string"
|
||||
int(0) != string(3) "123"
|
||||
int(0) != string(3) "2.5"
|
||||
int(0) == NULL
|
||||
int(0) != bool(true)
|
||||
int(0) == bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#1 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#2 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= object(test)#3 (0) {}
|
||||
int(0) != array(0) {}
|
||||
int(0) != int(-2147483648)
|
||||
int(0) != string(11) "-2147483648"
|
||||
string(6) "string" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" != string(0) ""
|
||||
string(6) "string" != int(1)
|
||||
string(6) "string" != float(2.5)
|
||||
string(6) "string" == int(0)
|
||||
string(6) "string" == string(6) "string"
|
||||
string(6) "string" != string(3) "123"
|
||||
string(6) "string" != string(3) "2.5"
|
||||
string(6) "string" != NULL
|
||||
string(6) "string" == bool(true)
|
||||
string(6) "string" != bool(false)
|
||||
string(6) "string" != object(stdClass)#1 (0) {}
|
||||
string(6) "string" != object(stdClass)#2 (0) {}
|
||||
string(6) "string" != object(test)#3 (0) {}
|
||||
string(6) "string" != array(0) {}
|
||||
string(6) "string" != int(-2147483648)
|
||||
string(6) "string" != string(11) "-2147483648"
|
||||
string(3) "123" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" != string(0) ""
|
||||
string(3) "123" != int(1)
|
||||
string(3) "123" != float(2.5)
|
||||
string(3) "123" != int(0)
|
||||
string(3) "123" != string(6) "string"
|
||||
string(3) "123" == string(3) "123"
|
||||
string(3) "123" != string(3) "2.5"
|
||||
string(3) "123" != NULL
|
||||
string(3) "123" == bool(true)
|
||||
string(3) "123" != bool(false)
|
||||
string(3) "123" != object(stdClass)#1 (0) {}
|
||||
string(3) "123" != object(stdClass)#2 (0) {}
|
||||
string(3) "123" != object(test)#3 (0) {}
|
||||
string(3) "123" != array(0) {}
|
||||
string(3) "123" != int(-2147483648)
|
||||
string(3) "123" != string(11) "-2147483648"
|
||||
string(3) "2.5" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" != string(0) ""
|
||||
string(3) "2.5" != int(1)
|
||||
string(3) "2.5" == float(2.5)
|
||||
string(3) "2.5" != int(0)
|
||||
string(3) "2.5" != string(6) "string"
|
||||
string(3) "2.5" != string(3) "123"
|
||||
string(3) "2.5" == string(3) "2.5"
|
||||
string(3) "2.5" != NULL
|
||||
string(3) "2.5" == bool(true)
|
||||
string(3) "2.5" != bool(false)
|
||||
string(3) "2.5" != object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" != object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" != object(test)#3 (0) {}
|
||||
string(3) "2.5" != array(0) {}
|
||||
string(3) "2.5" != int(-2147483648)
|
||||
string(3) "2.5" != string(11) "-2147483648"
|
||||
NULL != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL == string(0) ""
|
||||
NULL != int(1)
|
||||
NULL != float(2.5)
|
||||
NULL == int(0)
|
||||
NULL != string(6) "string"
|
||||
NULL != string(3) "123"
|
||||
NULL != string(3) "2.5"
|
||||
NULL == NULL
|
||||
NULL != bool(true)
|
||||
NULL == bool(false)
|
||||
NULL != object(stdClass)#1 (0) {}
|
||||
NULL != object(stdClass)#2 (0) {}
|
||||
NULL != object(test)#3 (0) {}
|
||||
NULL == array(0) {}
|
||||
NULL != int(-2147483648)
|
||||
NULL != string(11) "-2147483648"
|
||||
bool(true) == array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) != string(0) ""
|
||||
bool(true) == int(1)
|
||||
bool(true) == float(2.5)
|
||||
bool(true) != int(0)
|
||||
bool(true) == string(6) "string"
|
||||
bool(true) == string(3) "123"
|
||||
bool(true) == string(3) "2.5"
|
||||
bool(true) != NULL
|
||||
bool(true) == bool(true)
|
||||
bool(true) != bool(false)
|
||||
bool(true) == object(stdClass)#1 (0) {}
|
||||
bool(true) == object(stdClass)#2 (0) {}
|
||||
bool(true) == object(test)#3 (0) {}
|
||||
bool(true) != array(0) {}
|
||||
bool(true) == int(-2147483648)
|
||||
bool(true) == string(11) "-2147483648"
|
||||
bool(false) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) == string(0) ""
|
||||
bool(false) != int(1)
|
||||
bool(false) != float(2.5)
|
||||
bool(false) == int(0)
|
||||
bool(false) != string(6) "string"
|
||||
bool(false) != string(3) "123"
|
||||
bool(false) != string(3) "2.5"
|
||||
bool(false) == NULL
|
||||
bool(false) != bool(true)
|
||||
bool(false) == bool(false)
|
||||
bool(false) != object(stdClass)#1 (0) {}
|
||||
bool(false) != object(stdClass)#2 (0) {}
|
||||
bool(false) != object(test)#3 (0) {}
|
||||
bool(false) == array(0) {}
|
||||
bool(false) != int(-2147483648)
|
||||
bool(false) != string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} != string(0) ""
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(stdClass)#1 (0) {} != string(6) "string"
|
||||
object(stdClass)#1 (0) {} != string(3) "123"
|
||||
object(stdClass)#1 (0) {} != string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} != NULL
|
||||
object(stdClass)#1 (0) {} == bool(true)
|
||||
object(stdClass)#1 (0) {} != bool(false)
|
||||
object(stdClass)#1 (0) {} == object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} == object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} != object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} != array(0) {}
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(-2147483648)
|
||||
object(stdClass)#1 (0) {} != string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} != string(0) ""
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(stdClass)#2 (0) {} != string(6) "string"
|
||||
object(stdClass)#2 (0) {} != string(3) "123"
|
||||
object(stdClass)#2 (0) {} != string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} != NULL
|
||||
object(stdClass)#2 (0) {} == bool(true)
|
||||
object(stdClass)#2 (0) {} != bool(false)
|
||||
object(stdClass)#2 (0) {} == object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} == object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} != object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} != array(0) {}
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(-2147483648)
|
||||
object(stdClass)#2 (0) {} != string(11) "-2147483648"
|
||||
object(test)#3 (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} != string(0) ""
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(test)#3 (0) {} != string(6) "string"
|
||||
object(test)#3 (0) {} != string(3) "123"
|
||||
object(test)#3 (0) {} != string(3) "2.5"
|
||||
object(test)#3 (0) {} != NULL
|
||||
object(test)#3 (0) {} == bool(true)
|
||||
object(test)#3 (0) {} != bool(false)
|
||||
object(test)#3 (0) {} != object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} != object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} == object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} != array(0) {}
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= int(-2147483648)
|
||||
object(test)#3 (0) {} != string(11) "-2147483648"
|
||||
array(0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} != string(0) ""
|
||||
array(0) {} != int(1)
|
||||
array(0) {} != float(2.5)
|
||||
array(0) {} != int(0)
|
||||
array(0) {} != string(6) "string"
|
||||
array(0) {} != string(3) "123"
|
||||
array(0) {} != string(3) "2.5"
|
||||
array(0) {} == NULL
|
||||
array(0) {} != bool(true)
|
||||
array(0) {} == bool(false)
|
||||
array(0) {} != object(stdClass)#1 (0) {}
|
||||
array(0) {} != object(stdClass)#2 (0) {}
|
||||
array(0) {} != object(test)#3 (0) {}
|
||||
array(0) {} == array(0) {}
|
||||
array(0) {} != int(-2147483648)
|
||||
array(0) {} != string(11) "-2147483648"
|
||||
int(-2147483648) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) != string(0) ""
|
||||
int(-2147483648) != int(1)
|
||||
int(-2147483648) != float(2.5)
|
||||
int(-2147483648) != int(0)
|
||||
int(-2147483648) != string(6) "string"
|
||||
int(-2147483648) != string(3) "123"
|
||||
int(-2147483648) != string(3) "2.5"
|
||||
int(-2147483648) != NULL
|
||||
int(-2147483648) == bool(true)
|
||||
int(-2147483648) != bool(false)
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#1 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#2 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= object(test)#3 (0) {}
|
||||
int(-2147483648) != array(0) {}
|
||||
int(-2147483648) == int(-2147483648)
|
||||
int(-2147483648) == string(11) "-2147483648"
|
||||
string(11) "-2147483648" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" != string(0) ""
|
||||
string(11) "-2147483648" != int(1)
|
||||
string(11) "-2147483648" != float(2.5)
|
||||
string(11) "-2147483648" != int(0)
|
||||
string(11) "-2147483648" != string(6) "string"
|
||||
string(11) "-2147483648" != string(3) "123"
|
||||
string(11) "-2147483648" != string(3) "2.5"
|
||||
string(11) "-2147483648" != NULL
|
||||
string(11) "-2147483648" == bool(true)
|
||||
string(11) "-2147483648" != bool(false)
|
||||
string(11) "-2147483648" != object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" != object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" != object(test)#3 (0) {}
|
||||
string(11) "-2147483648" != array(0) {}
|
||||
string(11) "-2147483648" == int(-2147483648)
|
||||
string(11) "-2147483648" == string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables for equality
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var == $a[$i]) ? " == " : " != ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} == array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} == bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} != string(20) "-9223372036854775808"
|
||||
string(0) "" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" == string(0) ""
|
||||
string(0) "" != int(1)
|
||||
string(0) "" != float(2.5)
|
||||
string(0) "" == int(0)
|
||||
string(0) "" != string(6) "string"
|
||||
string(0) "" != string(3) "123"
|
||||
string(0) "" != string(3) "2.5"
|
||||
string(0) "" == NULL
|
||||
string(0) "" != bool(true)
|
||||
string(0) "" == bool(false)
|
||||
string(0) "" != object(stdClass)#%d (0) {}
|
||||
string(0) "" != object(stdClass)#%d (0) {}
|
||||
string(0) "" != object(test)#%d (0) {}
|
||||
string(0) "" != array(0) {}
|
||||
string(0) "" != int(-9223372036854775808)
|
||||
string(0) "" != string(20) "-9223372036854775808"
|
||||
int(1) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) != string(0) ""
|
||||
int(1) == int(1)
|
||||
int(1) != float(2.5)
|
||||
int(1) != int(0)
|
||||
int(1) != string(6) "string"
|
||||
int(1) != string(3) "123"
|
||||
int(1) != string(3) "2.5"
|
||||
int(1) != NULL
|
||||
int(1) == bool(true)
|
||||
int(1) != bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
== object(test)#%d (0) {}
|
||||
int(1) != array(0) {}
|
||||
int(1) != int(-9223372036854775808)
|
||||
int(1) != string(20) "-9223372036854775808"
|
||||
float(2.5) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) != string(0) ""
|
||||
float(2.5) != int(1)
|
||||
float(2.5) == float(2.5)
|
||||
float(2.5) != int(0)
|
||||
float(2.5) != string(6) "string"
|
||||
float(2.5) != string(3) "123"
|
||||
float(2.5) == string(3) "2.5"
|
||||
float(2.5) != NULL
|
||||
float(2.5) == bool(true)
|
||||
float(2.5) != bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
!= object(test)#%d (0) {}
|
||||
float(2.5) != array(0) {}
|
||||
float(2.5) != int(-9223372036854775808)
|
||||
float(2.5) != string(20) "-9223372036854775808"
|
||||
int(0) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) == string(0) ""
|
||||
int(0) != int(1)
|
||||
int(0) != float(2.5)
|
||||
int(0) == int(0)
|
||||
int(0) == string(6) "string"
|
||||
int(0) != string(3) "123"
|
||||
int(0) != string(3) "2.5"
|
||||
int(0) == NULL
|
||||
int(0) != bool(true)
|
||||
int(0) == bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= object(test)#%d (0) {}
|
||||
int(0) != array(0) {}
|
||||
int(0) != int(-9223372036854775808)
|
||||
int(0) != string(20) "-9223372036854775808"
|
||||
string(6) "string" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" != string(0) ""
|
||||
string(6) "string" != int(1)
|
||||
string(6) "string" != float(2.5)
|
||||
string(6) "string" == int(0)
|
||||
string(6) "string" == string(6) "string"
|
||||
string(6) "string" != string(3) "123"
|
||||
string(6) "string" != string(3) "2.5"
|
||||
string(6) "string" != NULL
|
||||
string(6) "string" == bool(true)
|
||||
string(6) "string" != bool(false)
|
||||
string(6) "string" != object(stdClass)#%d (0) {}
|
||||
string(6) "string" != object(stdClass)#%d (0) {}
|
||||
string(6) "string" != object(test)#%d (0) {}
|
||||
string(6) "string" != array(0) {}
|
||||
string(6) "string" != int(-9223372036854775808)
|
||||
string(6) "string" != string(20) "-9223372036854775808"
|
||||
string(3) "123" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" != string(0) ""
|
||||
string(3) "123" != int(1)
|
||||
string(3) "123" != float(2.5)
|
||||
string(3) "123" != int(0)
|
||||
string(3) "123" != string(6) "string"
|
||||
string(3) "123" == string(3) "123"
|
||||
string(3) "123" != string(3) "2.5"
|
||||
string(3) "123" != NULL
|
||||
string(3) "123" == bool(true)
|
||||
string(3) "123" != bool(false)
|
||||
string(3) "123" != object(stdClass)#%d (0) {}
|
||||
string(3) "123" != object(stdClass)#%d (0) {}
|
||||
string(3) "123" != object(test)#%d (0) {}
|
||||
string(3) "123" != array(0) {}
|
||||
string(3) "123" != int(-9223372036854775808)
|
||||
string(3) "123" != string(20) "-9223372036854775808"
|
||||
string(3) "2.5" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" != string(0) ""
|
||||
string(3) "2.5" != int(1)
|
||||
string(3) "2.5" == float(2.5)
|
||||
string(3) "2.5" != int(0)
|
||||
string(3) "2.5" != string(6) "string"
|
||||
string(3) "2.5" != string(3) "123"
|
||||
string(3) "2.5" == string(3) "2.5"
|
||||
string(3) "2.5" != NULL
|
||||
string(3) "2.5" == bool(true)
|
||||
string(3) "2.5" != bool(false)
|
||||
string(3) "2.5" != object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" != object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" != object(test)#%d (0) {}
|
||||
string(3) "2.5" != array(0) {}
|
||||
string(3) "2.5" != int(-9223372036854775808)
|
||||
string(3) "2.5" != string(20) "-9223372036854775808"
|
||||
NULL != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL == string(0) ""
|
||||
NULL != int(1)
|
||||
NULL != float(2.5)
|
||||
NULL == int(0)
|
||||
NULL != string(6) "string"
|
||||
NULL != string(3) "123"
|
||||
NULL != string(3) "2.5"
|
||||
NULL == NULL
|
||||
NULL != bool(true)
|
||||
NULL == bool(false)
|
||||
NULL != object(stdClass)#%d (0) {}
|
||||
NULL != object(stdClass)#%d (0) {}
|
||||
NULL != object(test)#%d (0) {}
|
||||
NULL == array(0) {}
|
||||
NULL != int(-9223372036854775808)
|
||||
NULL != string(20) "-9223372036854775808"
|
||||
bool(true) == array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) != string(0) ""
|
||||
bool(true) == int(1)
|
||||
bool(true) == float(2.5)
|
||||
bool(true) != int(0)
|
||||
bool(true) == string(6) "string"
|
||||
bool(true) == string(3) "123"
|
||||
bool(true) == string(3) "2.5"
|
||||
bool(true) != NULL
|
||||
bool(true) == bool(true)
|
||||
bool(true) != bool(false)
|
||||
bool(true) == object(stdClass)#%d (0) {}
|
||||
bool(true) == object(stdClass)#%d (0) {}
|
||||
bool(true) == object(test)#%d (0) {}
|
||||
bool(true) != array(0) {}
|
||||
bool(true) == int(-9223372036854775808)
|
||||
bool(true) == string(20) "-9223372036854775808"
|
||||
bool(false) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) == string(0) ""
|
||||
bool(false) != int(1)
|
||||
bool(false) != float(2.5)
|
||||
bool(false) == int(0)
|
||||
bool(false) != string(6) "string"
|
||||
bool(false) != string(3) "123"
|
||||
bool(false) != string(3) "2.5"
|
||||
bool(false) == NULL
|
||||
bool(false) != bool(true)
|
||||
bool(false) == bool(false)
|
||||
bool(false) != object(stdClass)#%d (0) {}
|
||||
bool(false) != object(stdClass)#%d (0) {}
|
||||
bool(false) != object(test)#%d (0) {}
|
||||
bool(false) == array(0) {}
|
||||
bool(false) != int(-9223372036854775808)
|
||||
bool(false) != string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} != string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(stdClass)#%d (0) {} != string(6) "string"
|
||||
object(stdClass)#%d (0) {} != string(3) "123"
|
||||
object(stdClass)#%d (0) {} != string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} != NULL
|
||||
object(stdClass)#%d (0) {} == bool(true)
|
||||
object(stdClass)#%d (0) {} != bool(false)
|
||||
object(stdClass)#%d (0) {} == object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} == object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} != object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} != array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} != string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} != string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(stdClass)#%d (0) {} != string(6) "string"
|
||||
object(stdClass)#%d (0) {} != string(3) "123"
|
||||
object(stdClass)#%d (0) {} != string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} != NULL
|
||||
object(stdClass)#%d (0) {} == bool(true)
|
||||
object(stdClass)#%d (0) {} != bool(false)
|
||||
object(stdClass)#%d (0) {} == object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} == object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} != object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} != array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} != string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} != string(0) ""
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
== int(1)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
!= float(2.5)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= int(0)
|
||||
object(test)#%d (0) {} != string(6) "string"
|
||||
object(test)#%d (0) {} != string(3) "123"
|
||||
object(test)#%d (0) {} != string(3) "2.5"
|
||||
object(test)#%d (0) {} != NULL
|
||||
object(test)#%d (0) {} == bool(true)
|
||||
object(test)#%d (0) {} != bool(false)
|
||||
object(test)#%d (0) {} != object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} != object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} == object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} != array(0) {}
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= int(-9223372036854775808)
|
||||
object(test)#%d (0) {} != string(20) "-9223372036854775808"
|
||||
array(0) {} != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} != string(0) ""
|
||||
array(0) {} != int(1)
|
||||
array(0) {} != float(2.5)
|
||||
array(0) {} != int(0)
|
||||
array(0) {} != string(6) "string"
|
||||
array(0) {} != string(3) "123"
|
||||
array(0) {} != string(3) "2.5"
|
||||
array(0) {} == NULL
|
||||
array(0) {} != bool(true)
|
||||
array(0) {} == bool(false)
|
||||
array(0) {} != object(stdClass)#%d (0) {}
|
||||
array(0) {} != object(stdClass)#%d (0) {}
|
||||
array(0) {} != object(test)#%d (0) {}
|
||||
array(0) {} == array(0) {}
|
||||
array(0) {} != int(-9223372036854775808)
|
||||
array(0) {} != string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) != string(0) ""
|
||||
int(-9223372036854775808) != int(1)
|
||||
int(-9223372036854775808) != float(2.5)
|
||||
int(-9223372036854775808) != int(0)
|
||||
int(-9223372036854775808) != string(6) "string"
|
||||
int(-9223372036854775808) != string(3) "123"
|
||||
int(-9223372036854775808) != string(3) "2.5"
|
||||
int(-9223372036854775808) != NULL
|
||||
int(-9223372036854775808) == bool(true)
|
||||
int(-9223372036854775808) != bool(false)
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
!= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
!= object(test)#%d (0) {}
|
||||
int(-9223372036854775808) != array(0) {}
|
||||
int(-9223372036854775808) == int(-9223372036854775808)
|
||||
int(-9223372036854775808) == string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" != array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" != string(0) ""
|
||||
string(20) "-9223372036854775808" != int(1)
|
||||
string(20) "-9223372036854775808" != float(2.5)
|
||||
string(20) "-9223372036854775808" != int(0)
|
||||
string(20) "-9223372036854775808" != string(6) "string"
|
||||
string(20) "-9223372036854775808" != string(3) "123"
|
||||
string(20) "-9223372036854775808" != string(3) "2.5"
|
||||
string(20) "-9223372036854775808" != NULL
|
||||
string(20) "-9223372036854775808" == bool(true)
|
||||
string(20) "-9223372036854775808" != bool(false)
|
||||
string(20) "-9223372036854775808" != object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" != object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" != object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" != array(0) {}
|
||||
string(20) "-9223372036854775808" == int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" == string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,341 @@
|
||||
--TEST--
|
||||
comparing different variables for identity
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var === $a[$i]) ? " === " : " !== ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} === array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(11) "-2147483648"
|
||||
string(0) "" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" === string(0) ""
|
||||
string(0) "" !== int(1)
|
||||
string(0) "" !== float(2.5)
|
||||
string(0) "" !== int(0)
|
||||
string(0) "" !== string(6) "string"
|
||||
string(0) "" !== string(3) "123"
|
||||
string(0) "" !== string(3) "2.5"
|
||||
string(0) "" !== NULL
|
||||
string(0) "" !== bool(true)
|
||||
string(0) "" !== bool(false)
|
||||
string(0) "" !== object(stdClass)#1 (0) {}
|
||||
string(0) "" !== object(stdClass)#2 (0) {}
|
||||
string(0) "" !== object(test)#3 (0) {}
|
||||
string(0) "" !== array(0) {}
|
||||
string(0) "" !== int(-2147483648)
|
||||
string(0) "" !== string(11) "-2147483648"
|
||||
int(1) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) !== string(0) ""
|
||||
int(1) === int(1)
|
||||
int(1) !== float(2.5)
|
||||
int(1) !== int(0)
|
||||
int(1) !== string(6) "string"
|
||||
int(1) !== string(3) "123"
|
||||
int(1) !== string(3) "2.5"
|
||||
int(1) !== NULL
|
||||
int(1) !== bool(true)
|
||||
int(1) !== bool(false)
|
||||
int(1) !== object(stdClass)#1 (0) {}
|
||||
int(1) !== object(stdClass)#2 (0) {}
|
||||
int(1) !== object(test)#3 (0) {}
|
||||
int(1) !== array(0) {}
|
||||
int(1) !== int(-2147483648)
|
||||
int(1) !== string(11) "-2147483648"
|
||||
float(2.5) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) !== string(0) ""
|
||||
float(2.5) !== int(1)
|
||||
float(2.5) === float(2.5)
|
||||
float(2.5) !== int(0)
|
||||
float(2.5) !== string(6) "string"
|
||||
float(2.5) !== string(3) "123"
|
||||
float(2.5) !== string(3) "2.5"
|
||||
float(2.5) !== NULL
|
||||
float(2.5) !== bool(true)
|
||||
float(2.5) !== bool(false)
|
||||
float(2.5) !== object(stdClass)#1 (0) {}
|
||||
float(2.5) !== object(stdClass)#2 (0) {}
|
||||
float(2.5) !== object(test)#3 (0) {}
|
||||
float(2.5) !== array(0) {}
|
||||
float(2.5) !== int(-2147483648)
|
||||
float(2.5) !== string(11) "-2147483648"
|
||||
int(0) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) !== string(0) ""
|
||||
int(0) !== int(1)
|
||||
int(0) !== float(2.5)
|
||||
int(0) === int(0)
|
||||
int(0) !== string(6) "string"
|
||||
int(0) !== string(3) "123"
|
||||
int(0) !== string(3) "2.5"
|
||||
int(0) !== NULL
|
||||
int(0) !== bool(true)
|
||||
int(0) !== bool(false)
|
||||
int(0) !== object(stdClass)#1 (0) {}
|
||||
int(0) !== object(stdClass)#2 (0) {}
|
||||
int(0) !== object(test)#3 (0) {}
|
||||
int(0) !== array(0) {}
|
||||
int(0) !== int(-2147483648)
|
||||
int(0) !== string(11) "-2147483648"
|
||||
string(6) "string" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" !== string(0) ""
|
||||
string(6) "string" !== int(1)
|
||||
string(6) "string" !== float(2.5)
|
||||
string(6) "string" !== int(0)
|
||||
string(6) "string" === string(6) "string"
|
||||
string(6) "string" !== string(3) "123"
|
||||
string(6) "string" !== string(3) "2.5"
|
||||
string(6) "string" !== NULL
|
||||
string(6) "string" !== bool(true)
|
||||
string(6) "string" !== bool(false)
|
||||
string(6) "string" !== object(stdClass)#1 (0) {}
|
||||
string(6) "string" !== object(stdClass)#2 (0) {}
|
||||
string(6) "string" !== object(test)#3 (0) {}
|
||||
string(6) "string" !== array(0) {}
|
||||
string(6) "string" !== int(-2147483648)
|
||||
string(6) "string" !== string(11) "-2147483648"
|
||||
string(3) "123" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" !== string(0) ""
|
||||
string(3) "123" !== int(1)
|
||||
string(3) "123" !== float(2.5)
|
||||
string(3) "123" !== int(0)
|
||||
string(3) "123" !== string(6) "string"
|
||||
string(3) "123" === string(3) "123"
|
||||
string(3) "123" !== string(3) "2.5"
|
||||
string(3) "123" !== NULL
|
||||
string(3) "123" !== bool(true)
|
||||
string(3) "123" !== bool(false)
|
||||
string(3) "123" !== object(stdClass)#1 (0) {}
|
||||
string(3) "123" !== object(stdClass)#2 (0) {}
|
||||
string(3) "123" !== object(test)#3 (0) {}
|
||||
string(3) "123" !== array(0) {}
|
||||
string(3) "123" !== int(-2147483648)
|
||||
string(3) "123" !== string(11) "-2147483648"
|
||||
string(3) "2.5" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" !== string(0) ""
|
||||
string(3) "2.5" !== int(1)
|
||||
string(3) "2.5" !== float(2.5)
|
||||
string(3) "2.5" !== int(0)
|
||||
string(3) "2.5" !== string(6) "string"
|
||||
string(3) "2.5" !== string(3) "123"
|
||||
string(3) "2.5" === string(3) "2.5"
|
||||
string(3) "2.5" !== NULL
|
||||
string(3) "2.5" !== bool(true)
|
||||
string(3) "2.5" !== bool(false)
|
||||
string(3) "2.5" !== object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" !== object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" !== object(test)#3 (0) {}
|
||||
string(3) "2.5" !== array(0) {}
|
||||
string(3) "2.5" !== int(-2147483648)
|
||||
string(3) "2.5" !== string(11) "-2147483648"
|
||||
NULL !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL !== string(0) ""
|
||||
NULL !== int(1)
|
||||
NULL !== float(2.5)
|
||||
NULL !== int(0)
|
||||
NULL !== string(6) "string"
|
||||
NULL !== string(3) "123"
|
||||
NULL !== string(3) "2.5"
|
||||
NULL === NULL
|
||||
NULL !== bool(true)
|
||||
NULL !== bool(false)
|
||||
NULL !== object(stdClass)#1 (0) {}
|
||||
NULL !== object(stdClass)#2 (0) {}
|
||||
NULL !== object(test)#3 (0) {}
|
||||
NULL !== array(0) {}
|
||||
NULL !== int(-2147483648)
|
||||
NULL !== string(11) "-2147483648"
|
||||
bool(true) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) !== string(0) ""
|
||||
bool(true) !== int(1)
|
||||
bool(true) !== float(2.5)
|
||||
bool(true) !== int(0)
|
||||
bool(true) !== string(6) "string"
|
||||
bool(true) !== string(3) "123"
|
||||
bool(true) !== string(3) "2.5"
|
||||
bool(true) !== NULL
|
||||
bool(true) === bool(true)
|
||||
bool(true) !== bool(false)
|
||||
bool(true) !== object(stdClass)#1 (0) {}
|
||||
bool(true) !== object(stdClass)#2 (0) {}
|
||||
bool(true) !== object(test)#3 (0) {}
|
||||
bool(true) !== array(0) {}
|
||||
bool(true) !== int(-2147483648)
|
||||
bool(true) !== string(11) "-2147483648"
|
||||
bool(false) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) !== string(0) ""
|
||||
bool(false) !== int(1)
|
||||
bool(false) !== float(2.5)
|
||||
bool(false) !== int(0)
|
||||
bool(false) !== string(6) "string"
|
||||
bool(false) !== string(3) "123"
|
||||
bool(false) !== string(3) "2.5"
|
||||
bool(false) !== NULL
|
||||
bool(false) !== bool(true)
|
||||
bool(false) === bool(false)
|
||||
bool(false) !== object(stdClass)#1 (0) {}
|
||||
bool(false) !== object(stdClass)#2 (0) {}
|
||||
bool(false) !== object(test)#3 (0) {}
|
||||
bool(false) !== array(0) {}
|
||||
bool(false) !== int(-2147483648)
|
||||
bool(false) !== string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} !== string(0) ""
|
||||
object(stdClass)#1 (0) {} !== int(1)
|
||||
object(stdClass)#1 (0) {} !== float(2.5)
|
||||
object(stdClass)#1 (0) {} !== int(0)
|
||||
object(stdClass)#1 (0) {} !== string(6) "string"
|
||||
object(stdClass)#1 (0) {} !== string(3) "123"
|
||||
object(stdClass)#1 (0) {} !== string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} !== NULL
|
||||
object(stdClass)#1 (0) {} !== bool(true)
|
||||
object(stdClass)#1 (0) {} !== bool(false)
|
||||
object(stdClass)#1 (0) {} === object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} !== object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} !== object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} !== array(0) {}
|
||||
object(stdClass)#1 (0) {} !== int(-2147483648)
|
||||
object(stdClass)#1 (0) {} !== string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} !== string(0) ""
|
||||
object(stdClass)#2 (0) {} !== int(1)
|
||||
object(stdClass)#2 (0) {} !== float(2.5)
|
||||
object(stdClass)#2 (0) {} !== int(0)
|
||||
object(stdClass)#2 (0) {} !== string(6) "string"
|
||||
object(stdClass)#2 (0) {} !== string(3) "123"
|
||||
object(stdClass)#2 (0) {} !== string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} !== NULL
|
||||
object(stdClass)#2 (0) {} !== bool(true)
|
||||
object(stdClass)#2 (0) {} !== bool(false)
|
||||
object(stdClass)#2 (0) {} !== object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} === object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} !== object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} !== array(0) {}
|
||||
object(stdClass)#2 (0) {} !== int(-2147483648)
|
||||
object(stdClass)#2 (0) {} !== string(11) "-2147483648"
|
||||
object(test)#3 (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} !== string(0) ""
|
||||
object(test)#3 (0) {} !== int(1)
|
||||
object(test)#3 (0) {} !== float(2.5)
|
||||
object(test)#3 (0) {} !== int(0)
|
||||
object(test)#3 (0) {} !== string(6) "string"
|
||||
object(test)#3 (0) {} !== string(3) "123"
|
||||
object(test)#3 (0) {} !== string(3) "2.5"
|
||||
object(test)#3 (0) {} !== NULL
|
||||
object(test)#3 (0) {} !== bool(true)
|
||||
object(test)#3 (0) {} !== bool(false)
|
||||
object(test)#3 (0) {} !== object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} !== object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} === object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} !== array(0) {}
|
||||
object(test)#3 (0) {} !== int(-2147483648)
|
||||
object(test)#3 (0) {} !== string(11) "-2147483648"
|
||||
array(0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} !== string(0) ""
|
||||
array(0) {} !== int(1)
|
||||
array(0) {} !== float(2.5)
|
||||
array(0) {} !== int(0)
|
||||
array(0) {} !== string(6) "string"
|
||||
array(0) {} !== string(3) "123"
|
||||
array(0) {} !== string(3) "2.5"
|
||||
array(0) {} !== NULL
|
||||
array(0) {} !== bool(true)
|
||||
array(0) {} !== bool(false)
|
||||
array(0) {} !== object(stdClass)#1 (0) {}
|
||||
array(0) {} !== object(stdClass)#2 (0) {}
|
||||
array(0) {} !== object(test)#3 (0) {}
|
||||
array(0) {} === array(0) {}
|
||||
array(0) {} !== int(-2147483648)
|
||||
array(0) {} !== string(11) "-2147483648"
|
||||
int(-2147483648) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) !== string(0) ""
|
||||
int(-2147483648) !== int(1)
|
||||
int(-2147483648) !== float(2.5)
|
||||
int(-2147483648) !== int(0)
|
||||
int(-2147483648) !== string(6) "string"
|
||||
int(-2147483648) !== string(3) "123"
|
||||
int(-2147483648) !== string(3) "2.5"
|
||||
int(-2147483648) !== NULL
|
||||
int(-2147483648) !== bool(true)
|
||||
int(-2147483648) !== bool(false)
|
||||
int(-2147483648) !== object(stdClass)#1 (0) {}
|
||||
int(-2147483648) !== object(stdClass)#2 (0) {}
|
||||
int(-2147483648) !== object(test)#3 (0) {}
|
||||
int(-2147483648) !== array(0) {}
|
||||
int(-2147483648) === int(-2147483648)
|
||||
int(-2147483648) !== string(11) "-2147483648"
|
||||
string(11) "-2147483648" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" !== string(0) ""
|
||||
string(11) "-2147483648" !== int(1)
|
||||
string(11) "-2147483648" !== float(2.5)
|
||||
string(11) "-2147483648" !== int(0)
|
||||
string(11) "-2147483648" !== string(6) "string"
|
||||
string(11) "-2147483648" !== string(3) "123"
|
||||
string(11) "-2147483648" !== string(3) "2.5"
|
||||
string(11) "-2147483648" !== NULL
|
||||
string(11) "-2147483648" !== bool(true)
|
||||
string(11) "-2147483648" !== bool(false)
|
||||
string(11) "-2147483648" !== object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" !== object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" !== object(test)#3 (0) {}
|
||||
string(11) "-2147483648" !== array(0) {}
|
||||
string(11) "-2147483648" !== int(-2147483648)
|
||||
string(11) "-2147483648" === string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,341 @@
|
||||
--TEST--
|
||||
comparing different variables for identity
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var === $a[$i]) ? " === " : " !== ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} === array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} !== string(20) "-9223372036854775808"
|
||||
string(0) "" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" === string(0) ""
|
||||
string(0) "" !== int(1)
|
||||
string(0) "" !== float(2.5)
|
||||
string(0) "" !== int(0)
|
||||
string(0) "" !== string(6) "string"
|
||||
string(0) "" !== string(3) "123"
|
||||
string(0) "" !== string(3) "2.5"
|
||||
string(0) "" !== NULL
|
||||
string(0) "" !== bool(true)
|
||||
string(0) "" !== bool(false)
|
||||
string(0) "" !== object(stdClass)#%d (0) {}
|
||||
string(0) "" !== object(stdClass)#%d (0) {}
|
||||
string(0) "" !== object(test)#%d (0) {}
|
||||
string(0) "" !== array(0) {}
|
||||
string(0) "" !== int(-9223372036854775808)
|
||||
string(0) "" !== string(20) "-9223372036854775808"
|
||||
int(1) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) !== string(0) ""
|
||||
int(1) === int(1)
|
||||
int(1) !== float(2.5)
|
||||
int(1) !== int(0)
|
||||
int(1) !== string(6) "string"
|
||||
int(1) !== string(3) "123"
|
||||
int(1) !== string(3) "2.5"
|
||||
int(1) !== NULL
|
||||
int(1) !== bool(true)
|
||||
int(1) !== bool(false)
|
||||
int(1) !== object(stdClass)#%d (0) {}
|
||||
int(1) !== object(stdClass)#%d (0) {}
|
||||
int(1) !== object(test)#%d (0) {}
|
||||
int(1) !== array(0) {}
|
||||
int(1) !== int(-9223372036854775808)
|
||||
int(1) !== string(20) "-9223372036854775808"
|
||||
float(2.5) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) !== string(0) ""
|
||||
float(2.5) !== int(1)
|
||||
float(2.5) === float(2.5)
|
||||
float(2.5) !== int(0)
|
||||
float(2.5) !== string(6) "string"
|
||||
float(2.5) !== string(3) "123"
|
||||
float(2.5) !== string(3) "2.5"
|
||||
float(2.5) !== NULL
|
||||
float(2.5) !== bool(true)
|
||||
float(2.5) !== bool(false)
|
||||
float(2.5) !== object(stdClass)#%d (0) {}
|
||||
float(2.5) !== object(stdClass)#%d (0) {}
|
||||
float(2.5) !== object(test)#%d (0) {}
|
||||
float(2.5) !== array(0) {}
|
||||
float(2.5) !== int(-9223372036854775808)
|
||||
float(2.5) !== string(20) "-9223372036854775808"
|
||||
int(0) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) !== string(0) ""
|
||||
int(0) !== int(1)
|
||||
int(0) !== float(2.5)
|
||||
int(0) === int(0)
|
||||
int(0) !== string(6) "string"
|
||||
int(0) !== string(3) "123"
|
||||
int(0) !== string(3) "2.5"
|
||||
int(0) !== NULL
|
||||
int(0) !== bool(true)
|
||||
int(0) !== bool(false)
|
||||
int(0) !== object(stdClass)#%d (0) {}
|
||||
int(0) !== object(stdClass)#%d (0) {}
|
||||
int(0) !== object(test)#%d (0) {}
|
||||
int(0) !== array(0) {}
|
||||
int(0) !== int(-9223372036854775808)
|
||||
int(0) !== string(20) "-9223372036854775808"
|
||||
string(6) "string" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" !== string(0) ""
|
||||
string(6) "string" !== int(1)
|
||||
string(6) "string" !== float(2.5)
|
||||
string(6) "string" !== int(0)
|
||||
string(6) "string" === string(6) "string"
|
||||
string(6) "string" !== string(3) "123"
|
||||
string(6) "string" !== string(3) "2.5"
|
||||
string(6) "string" !== NULL
|
||||
string(6) "string" !== bool(true)
|
||||
string(6) "string" !== bool(false)
|
||||
string(6) "string" !== object(stdClass)#%d (0) {}
|
||||
string(6) "string" !== object(stdClass)#%d (0) {}
|
||||
string(6) "string" !== object(test)#%d (0) {}
|
||||
string(6) "string" !== array(0) {}
|
||||
string(6) "string" !== int(-9223372036854775808)
|
||||
string(6) "string" !== string(20) "-9223372036854775808"
|
||||
string(3) "123" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" !== string(0) ""
|
||||
string(3) "123" !== int(1)
|
||||
string(3) "123" !== float(2.5)
|
||||
string(3) "123" !== int(0)
|
||||
string(3) "123" !== string(6) "string"
|
||||
string(3) "123" === string(3) "123"
|
||||
string(3) "123" !== string(3) "2.5"
|
||||
string(3) "123" !== NULL
|
||||
string(3) "123" !== bool(true)
|
||||
string(3) "123" !== bool(false)
|
||||
string(3) "123" !== object(stdClass)#%d (0) {}
|
||||
string(3) "123" !== object(stdClass)#%d (0) {}
|
||||
string(3) "123" !== object(test)#%d (0) {}
|
||||
string(3) "123" !== array(0) {}
|
||||
string(3) "123" !== int(-9223372036854775808)
|
||||
string(3) "123" !== string(20) "-9223372036854775808"
|
||||
string(3) "2.5" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" !== string(0) ""
|
||||
string(3) "2.5" !== int(1)
|
||||
string(3) "2.5" !== float(2.5)
|
||||
string(3) "2.5" !== int(0)
|
||||
string(3) "2.5" !== string(6) "string"
|
||||
string(3) "2.5" !== string(3) "123"
|
||||
string(3) "2.5" === string(3) "2.5"
|
||||
string(3) "2.5" !== NULL
|
||||
string(3) "2.5" !== bool(true)
|
||||
string(3) "2.5" !== bool(false)
|
||||
string(3) "2.5" !== object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" !== object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" !== object(test)#%d (0) {}
|
||||
string(3) "2.5" !== array(0) {}
|
||||
string(3) "2.5" !== int(-9223372036854775808)
|
||||
string(3) "2.5" !== string(20) "-9223372036854775808"
|
||||
NULL !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL !== string(0) ""
|
||||
NULL !== int(1)
|
||||
NULL !== float(2.5)
|
||||
NULL !== int(0)
|
||||
NULL !== string(6) "string"
|
||||
NULL !== string(3) "123"
|
||||
NULL !== string(3) "2.5"
|
||||
NULL === NULL
|
||||
NULL !== bool(true)
|
||||
NULL !== bool(false)
|
||||
NULL !== object(stdClass)#%d (0) {}
|
||||
NULL !== object(stdClass)#%d (0) {}
|
||||
NULL !== object(test)#%d (0) {}
|
||||
NULL !== array(0) {}
|
||||
NULL !== int(-9223372036854775808)
|
||||
NULL !== string(20) "-9223372036854775808"
|
||||
bool(true) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) !== string(0) ""
|
||||
bool(true) !== int(1)
|
||||
bool(true) !== float(2.5)
|
||||
bool(true) !== int(0)
|
||||
bool(true) !== string(6) "string"
|
||||
bool(true) !== string(3) "123"
|
||||
bool(true) !== string(3) "2.5"
|
||||
bool(true) !== NULL
|
||||
bool(true) === bool(true)
|
||||
bool(true) !== bool(false)
|
||||
bool(true) !== object(stdClass)#%d (0) {}
|
||||
bool(true) !== object(stdClass)#%d (0) {}
|
||||
bool(true) !== object(test)#%d (0) {}
|
||||
bool(true) !== array(0) {}
|
||||
bool(true) !== int(-9223372036854775808)
|
||||
bool(true) !== string(20) "-9223372036854775808"
|
||||
bool(false) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) !== string(0) ""
|
||||
bool(false) !== int(1)
|
||||
bool(false) !== float(2.5)
|
||||
bool(false) !== int(0)
|
||||
bool(false) !== string(6) "string"
|
||||
bool(false) !== string(3) "123"
|
||||
bool(false) !== string(3) "2.5"
|
||||
bool(false) !== NULL
|
||||
bool(false) !== bool(true)
|
||||
bool(false) === bool(false)
|
||||
bool(false) !== object(stdClass)#%d (0) {}
|
||||
bool(false) !== object(stdClass)#%d (0) {}
|
||||
bool(false) !== object(test)#%d (0) {}
|
||||
bool(false) !== array(0) {}
|
||||
bool(false) !== int(-9223372036854775808)
|
||||
bool(false) !== string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} !== string(0) ""
|
||||
object(stdClass)#%d (0) {} !== int(1)
|
||||
object(stdClass)#%d (0) {} !== float(2.5)
|
||||
object(stdClass)#%d (0) {} !== int(0)
|
||||
object(stdClass)#%d (0) {} !== string(6) "string"
|
||||
object(stdClass)#%d (0) {} !== string(3) "123"
|
||||
object(stdClass)#%d (0) {} !== string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} !== NULL
|
||||
object(stdClass)#%d (0) {} !== bool(true)
|
||||
object(stdClass)#%d (0) {} !== bool(false)
|
||||
object(stdClass)#%d (0) {} === object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} !== object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} !== object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} !== array(0) {}
|
||||
object(stdClass)#%d (0) {} !== int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} !== string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} !== string(0) ""
|
||||
object(stdClass)#%d (0) {} !== int(1)
|
||||
object(stdClass)#%d (0) {} !== float(2.5)
|
||||
object(stdClass)#%d (0) {} !== int(0)
|
||||
object(stdClass)#%d (0) {} !== string(6) "string"
|
||||
object(stdClass)#%d (0) {} !== string(3) "123"
|
||||
object(stdClass)#%d (0) {} !== string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} !== NULL
|
||||
object(stdClass)#%d (0) {} !== bool(true)
|
||||
object(stdClass)#%d (0) {} !== bool(false)
|
||||
object(stdClass)#%d (0) {} !== object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} === object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} !== object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} !== array(0) {}
|
||||
object(stdClass)#%d (0) {} !== int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} !== string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} !== string(0) ""
|
||||
object(test)#%d (0) {} !== int(1)
|
||||
object(test)#%d (0) {} !== float(2.5)
|
||||
object(test)#%d (0) {} !== int(0)
|
||||
object(test)#%d (0) {} !== string(6) "string"
|
||||
object(test)#%d (0) {} !== string(3) "123"
|
||||
object(test)#%d (0) {} !== string(3) "2.5"
|
||||
object(test)#%d (0) {} !== NULL
|
||||
object(test)#%d (0) {} !== bool(true)
|
||||
object(test)#%d (0) {} !== bool(false)
|
||||
object(test)#%d (0) {} !== object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} !== object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} === object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} !== array(0) {}
|
||||
object(test)#%d (0) {} !== int(-9223372036854775808)
|
||||
object(test)#%d (0) {} !== string(20) "-9223372036854775808"
|
||||
array(0) {} !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} !== string(0) ""
|
||||
array(0) {} !== int(1)
|
||||
array(0) {} !== float(2.5)
|
||||
array(0) {} !== int(0)
|
||||
array(0) {} !== string(6) "string"
|
||||
array(0) {} !== string(3) "123"
|
||||
array(0) {} !== string(3) "2.5"
|
||||
array(0) {} !== NULL
|
||||
array(0) {} !== bool(true)
|
||||
array(0) {} !== bool(false)
|
||||
array(0) {} !== object(stdClass)#%d (0) {}
|
||||
array(0) {} !== object(stdClass)#%d (0) {}
|
||||
array(0) {} !== object(test)#%d (0) {}
|
||||
array(0) {} === array(0) {}
|
||||
array(0) {} !== int(-9223372036854775808)
|
||||
array(0) {} !== string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) !== string(0) ""
|
||||
int(-9223372036854775808) !== int(1)
|
||||
int(-9223372036854775808) !== float(2.5)
|
||||
int(-9223372036854775808) !== int(0)
|
||||
int(-9223372036854775808) !== string(6) "string"
|
||||
int(-9223372036854775808) !== string(3) "123"
|
||||
int(-9223372036854775808) !== string(3) "2.5"
|
||||
int(-9223372036854775808) !== NULL
|
||||
int(-9223372036854775808) !== bool(true)
|
||||
int(-9223372036854775808) !== bool(false)
|
||||
int(-9223372036854775808) !== object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808) !== object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808) !== object(test)#%d (0) {}
|
||||
int(-9223372036854775808) !== array(0) {}
|
||||
int(-9223372036854775808) === int(-9223372036854775808)
|
||||
int(-9223372036854775808) !== string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" !== array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" !== string(0) ""
|
||||
string(20) "-9223372036854775808" !== int(1)
|
||||
string(20) "-9223372036854775808" !== float(2.5)
|
||||
string(20) "-9223372036854775808" !== int(0)
|
||||
string(20) "-9223372036854775808" !== string(6) "string"
|
||||
string(20) "-9223372036854775808" !== string(3) "123"
|
||||
string(20) "-9223372036854775808" !== string(3) "2.5"
|
||||
string(20) "-9223372036854775808" !== NULL
|
||||
string(20) "-9223372036854775808" !== bool(true)
|
||||
string(20) "-9223372036854775808" !== bool(false)
|
||||
string(20) "-9223372036854775808" !== object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" !== object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" !== object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" !== array(0) {}
|
||||
string(20) "-9223372036854775808" !== int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" === string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (greater than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var > $a[$i]) ? " > " : " <= ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(11) "-2147483648"
|
||||
string(0) "" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" <= string(0) ""
|
||||
string(0) "" <= int(1)
|
||||
string(0) "" <= float(2.5)
|
||||
string(0) "" <= int(0)
|
||||
string(0) "" <= string(6) "string"
|
||||
string(0) "" <= string(3) "123"
|
||||
string(0) "" <= string(3) "2.5"
|
||||
string(0) "" <= NULL
|
||||
string(0) "" <= bool(true)
|
||||
string(0) "" <= bool(false)
|
||||
string(0) "" <= object(stdClass)#1 (0) {}
|
||||
string(0) "" <= object(stdClass)#2 (0) {}
|
||||
string(0) "" <= object(test)#3 (0) {}
|
||||
string(0) "" <= array(0) {}
|
||||
string(0) "" > int(-2147483648)
|
||||
string(0) "" <= string(11) "-2147483648"
|
||||
int(1) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) > string(0) ""
|
||||
int(1) <= int(1)
|
||||
int(1) <= float(2.5)
|
||||
int(1) > int(0)
|
||||
int(1) > string(6) "string"
|
||||
int(1) <= string(3) "123"
|
||||
int(1) <= string(3) "2.5"
|
||||
int(1) > NULL
|
||||
int(1) <= bool(true)
|
||||
int(1) > bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(1) <= array(0) {}
|
||||
int(1) > int(-2147483648)
|
||||
int(1) > string(11) "-2147483648"
|
||||
float(2.5) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) > string(0) ""
|
||||
float(2.5) > int(1)
|
||||
float(2.5) <= float(2.5)
|
||||
float(2.5) > int(0)
|
||||
float(2.5) > string(6) "string"
|
||||
float(2.5) <= string(3) "123"
|
||||
float(2.5) <= string(3) "2.5"
|
||||
float(2.5) > NULL
|
||||
float(2.5) <= bool(true)
|
||||
float(2.5) > bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#1 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#2 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
> object(test)#3 (0) {}
|
||||
float(2.5) <= array(0) {}
|
||||
float(2.5) > int(-2147483648)
|
||||
float(2.5) > string(11) "-2147483648"
|
||||
int(0) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) <= string(0) ""
|
||||
int(0) <= int(1)
|
||||
int(0) <= float(2.5)
|
||||
int(0) <= int(0)
|
||||
int(0) <= string(6) "string"
|
||||
int(0) <= string(3) "123"
|
||||
int(0) <= string(3) "2.5"
|
||||
int(0) <= NULL
|
||||
int(0) <= bool(true)
|
||||
int(0) <= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(0) <= array(0) {}
|
||||
int(0) > int(-2147483648)
|
||||
int(0) > string(11) "-2147483648"
|
||||
string(6) "string" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" > string(0) ""
|
||||
string(6) "string" <= int(1)
|
||||
string(6) "string" <= float(2.5)
|
||||
string(6) "string" <= int(0)
|
||||
string(6) "string" <= string(6) "string"
|
||||
string(6) "string" > string(3) "123"
|
||||
string(6) "string" > string(3) "2.5"
|
||||
string(6) "string" > NULL
|
||||
string(6) "string" <= bool(true)
|
||||
string(6) "string" > bool(false)
|
||||
string(6) "string" <= object(stdClass)#1 (0) {}
|
||||
string(6) "string" <= object(stdClass)#2 (0) {}
|
||||
string(6) "string" <= object(test)#3 (0) {}
|
||||
string(6) "string" <= array(0) {}
|
||||
string(6) "string" > int(-2147483648)
|
||||
string(6) "string" > string(11) "-2147483648"
|
||||
string(3) "123" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" > string(0) ""
|
||||
string(3) "123" > int(1)
|
||||
string(3) "123" > float(2.5)
|
||||
string(3) "123" > int(0)
|
||||
string(3) "123" <= string(6) "string"
|
||||
string(3) "123" <= string(3) "123"
|
||||
string(3) "123" > string(3) "2.5"
|
||||
string(3) "123" > NULL
|
||||
string(3) "123" <= bool(true)
|
||||
string(3) "123" > bool(false)
|
||||
string(3) "123" <= object(stdClass)#1 (0) {}
|
||||
string(3) "123" <= object(stdClass)#2 (0) {}
|
||||
string(3) "123" <= object(test)#3 (0) {}
|
||||
string(3) "123" <= array(0) {}
|
||||
string(3) "123" > int(-2147483648)
|
||||
string(3) "123" > string(11) "-2147483648"
|
||||
string(3) "2.5" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" > string(0) ""
|
||||
string(3) "2.5" > int(1)
|
||||
string(3) "2.5" <= float(2.5)
|
||||
string(3) "2.5" > int(0)
|
||||
string(3) "2.5" <= string(6) "string"
|
||||
string(3) "2.5" <= string(3) "123"
|
||||
string(3) "2.5" <= string(3) "2.5"
|
||||
string(3) "2.5" > NULL
|
||||
string(3) "2.5" <= bool(true)
|
||||
string(3) "2.5" > bool(false)
|
||||
string(3) "2.5" <= object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" <= object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" <= object(test)#3 (0) {}
|
||||
string(3) "2.5" <= array(0) {}
|
||||
string(3) "2.5" > int(-2147483648)
|
||||
string(3) "2.5" > string(11) "-2147483648"
|
||||
NULL <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL <= string(0) ""
|
||||
NULL <= int(1)
|
||||
NULL <= float(2.5)
|
||||
NULL <= int(0)
|
||||
NULL <= string(6) "string"
|
||||
NULL <= string(3) "123"
|
||||
NULL <= string(3) "2.5"
|
||||
NULL <= NULL
|
||||
NULL <= bool(true)
|
||||
NULL <= bool(false)
|
||||
NULL <= object(stdClass)#1 (0) {}
|
||||
NULL <= object(stdClass)#2 (0) {}
|
||||
NULL <= object(test)#3 (0) {}
|
||||
NULL <= array(0) {}
|
||||
NULL <= int(-2147483648)
|
||||
NULL <= string(11) "-2147483648"
|
||||
bool(true) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) > string(0) ""
|
||||
bool(true) <= int(1)
|
||||
bool(true) <= float(2.5)
|
||||
bool(true) > int(0)
|
||||
bool(true) <= string(6) "string"
|
||||
bool(true) <= string(3) "123"
|
||||
bool(true) <= string(3) "2.5"
|
||||
bool(true) > NULL
|
||||
bool(true) <= bool(true)
|
||||
bool(true) > bool(false)
|
||||
bool(true) <= object(stdClass)#1 (0) {}
|
||||
bool(true) <= object(stdClass)#2 (0) {}
|
||||
bool(true) <= object(test)#3 (0) {}
|
||||
bool(true) > array(0) {}
|
||||
bool(true) <= int(-2147483648)
|
||||
bool(true) <= string(11) "-2147483648"
|
||||
bool(false) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) <= string(0) ""
|
||||
bool(false) <= int(1)
|
||||
bool(false) <= float(2.5)
|
||||
bool(false) <= int(0)
|
||||
bool(false) <= string(6) "string"
|
||||
bool(false) <= string(3) "123"
|
||||
bool(false) <= string(3) "2.5"
|
||||
bool(false) <= NULL
|
||||
bool(false) <= bool(true)
|
||||
bool(false) <= bool(false)
|
||||
bool(false) <= object(stdClass)#1 (0) {}
|
||||
bool(false) <= object(stdClass)#2 (0) {}
|
||||
bool(false) <= object(test)#3 (0) {}
|
||||
bool(false) <= array(0) {}
|
||||
bool(false) <= int(-2147483648)
|
||||
bool(false) <= string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} > string(0) ""
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#1 (0) {} > string(6) "string"
|
||||
object(stdClass)#1 (0) {} > string(3) "123"
|
||||
object(stdClass)#1 (0) {} > string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} > NULL
|
||||
object(stdClass)#1 (0) {} <= bool(true)
|
||||
object(stdClass)#1 (0) {} > bool(false)
|
||||
object(stdClass)#1 (0) {} <= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} <= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} <= object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} > array(0) {}
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(stdClass)#1 (0) {} > string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} > string(0) ""
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#2 (0) {} > string(6) "string"
|
||||
object(stdClass)#2 (0) {} > string(3) "123"
|
||||
object(stdClass)#2 (0) {} > string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} > NULL
|
||||
object(stdClass)#2 (0) {} <= bool(true)
|
||||
object(stdClass)#2 (0) {} > bool(false)
|
||||
object(stdClass)#2 (0) {} <= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} <= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} <= object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} > array(0) {}
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(stdClass)#2 (0) {} > string(11) "-2147483648"
|
||||
object(test)#3 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} > string(0) ""
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(test)#3 (0) {} > string(6) "string"
|
||||
object(test)#3 (0) {} > string(3) "123"
|
||||
object(test)#3 (0) {} > string(3) "2.5"
|
||||
object(test)#3 (0) {} > NULL
|
||||
object(test)#3 (0) {} <= bool(true)
|
||||
object(test)#3 (0) {} > bool(false)
|
||||
object(test)#3 (0) {} <= object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} <= object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} <= object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} > array(0) {}
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(test)#3 (0) {} > string(11) "-2147483648"
|
||||
array(0) {} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} > string(0) ""
|
||||
array(0) {} > int(1)
|
||||
array(0) {} > float(2.5)
|
||||
array(0) {} > int(0)
|
||||
array(0) {} > string(6) "string"
|
||||
array(0) {} > string(3) "123"
|
||||
array(0) {} > string(3) "2.5"
|
||||
array(0) {} <= NULL
|
||||
array(0) {} <= bool(true)
|
||||
array(0) {} <= bool(false)
|
||||
array(0) {} <= object(stdClass)#1 (0) {}
|
||||
array(0) {} <= object(stdClass)#2 (0) {}
|
||||
array(0) {} <= object(test)#3 (0) {}
|
||||
array(0) {} <= array(0) {}
|
||||
array(0) {} > int(-2147483648)
|
||||
array(0) {} > string(11) "-2147483648"
|
||||
int(-2147483648) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) <= string(0) ""
|
||||
int(-2147483648) <= int(1)
|
||||
int(-2147483648) <= float(2.5)
|
||||
int(-2147483648) <= int(0)
|
||||
int(-2147483648) <= string(6) "string"
|
||||
int(-2147483648) <= string(3) "123"
|
||||
int(-2147483648) <= string(3) "2.5"
|
||||
int(-2147483648) > NULL
|
||||
int(-2147483648) <= bool(true)
|
||||
int(-2147483648) > bool(false)
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(-2147483648) <= array(0) {}
|
||||
int(-2147483648) <= int(-2147483648)
|
||||
int(-2147483648) <= string(11) "-2147483648"
|
||||
string(11) "-2147483648" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" > string(0) ""
|
||||
string(11) "-2147483648" <= int(1)
|
||||
string(11) "-2147483648" <= float(2.5)
|
||||
string(11) "-2147483648" <= int(0)
|
||||
string(11) "-2147483648" <= string(6) "string"
|
||||
string(11) "-2147483648" <= string(3) "123"
|
||||
string(11) "-2147483648" <= string(3) "2.5"
|
||||
string(11) "-2147483648" > NULL
|
||||
string(11) "-2147483648" <= bool(true)
|
||||
string(11) "-2147483648" > bool(false)
|
||||
string(11) "-2147483648" <= object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" <= object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" <= object(test)#3 (0) {}
|
||||
string(11) "-2147483648" <= array(0) {}
|
||||
string(11) "-2147483648" <= int(-2147483648)
|
||||
string(11) "-2147483648" <= string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (greater than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var > $a[$i]) ? " > " : " <= ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(20) "-9223372036854775808"
|
||||
string(0) "" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" <= string(0) ""
|
||||
string(0) "" <= int(1)
|
||||
string(0) "" <= float(2.5)
|
||||
string(0) "" <= int(0)
|
||||
string(0) "" <= string(6) "string"
|
||||
string(0) "" <= string(3) "123"
|
||||
string(0) "" <= string(3) "2.5"
|
||||
string(0) "" <= NULL
|
||||
string(0) "" <= bool(true)
|
||||
string(0) "" <= bool(false)
|
||||
string(0) "" <= object(stdClass)#%d (0) {}
|
||||
string(0) "" <= object(stdClass)#%d (0) {}
|
||||
string(0) "" <= object(test)#%d (0) {}
|
||||
string(0) "" <= array(0) {}
|
||||
string(0) "" > int(-9223372036854775808)
|
||||
string(0) "" <= string(20) "-9223372036854775808"
|
||||
int(1) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) > string(0) ""
|
||||
int(1) <= int(1)
|
||||
int(1) <= float(2.5)
|
||||
int(1) > int(0)
|
||||
int(1) > string(6) "string"
|
||||
int(1) <= string(3) "123"
|
||||
int(1) <= string(3) "2.5"
|
||||
int(1) > NULL
|
||||
int(1) <= bool(true)
|
||||
int(1) > bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(1) <= array(0) {}
|
||||
int(1) > int(-9223372036854775808)
|
||||
int(1) > string(20) "-9223372036854775808"
|
||||
float(2.5) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) > string(0) ""
|
||||
float(2.5) > int(1)
|
||||
float(2.5) <= float(2.5)
|
||||
float(2.5) > int(0)
|
||||
float(2.5) > string(6) "string"
|
||||
float(2.5) <= string(3) "123"
|
||||
float(2.5) <= string(3) "2.5"
|
||||
float(2.5) > NULL
|
||||
float(2.5) <= bool(true)
|
||||
float(2.5) > bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
> object(test)#%d (0) {}
|
||||
float(2.5) <= array(0) {}
|
||||
float(2.5) > int(-9223372036854775808)
|
||||
float(2.5) > string(20) "-9223372036854775808"
|
||||
int(0) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) <= string(0) ""
|
||||
int(0) <= int(1)
|
||||
int(0) <= float(2.5)
|
||||
int(0) <= int(0)
|
||||
int(0) <= string(6) "string"
|
||||
int(0) <= string(3) "123"
|
||||
int(0) <= string(3) "2.5"
|
||||
int(0) <= NULL
|
||||
int(0) <= bool(true)
|
||||
int(0) <= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(0) <= array(0) {}
|
||||
int(0) > int(-9223372036854775808)
|
||||
int(0) > string(20) "-9223372036854775808"
|
||||
string(6) "string" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" > string(0) ""
|
||||
string(6) "string" <= int(1)
|
||||
string(6) "string" <= float(2.5)
|
||||
string(6) "string" <= int(0)
|
||||
string(6) "string" <= string(6) "string"
|
||||
string(6) "string" > string(3) "123"
|
||||
string(6) "string" > string(3) "2.5"
|
||||
string(6) "string" > NULL
|
||||
string(6) "string" <= bool(true)
|
||||
string(6) "string" > bool(false)
|
||||
string(6) "string" <= object(stdClass)#%d (0) {}
|
||||
string(6) "string" <= object(stdClass)#%d (0) {}
|
||||
string(6) "string" <= object(test)#%d (0) {}
|
||||
string(6) "string" <= array(0) {}
|
||||
string(6) "string" > int(-9223372036854775808)
|
||||
string(6) "string" > string(20) "-9223372036854775808"
|
||||
string(3) "123" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" > string(0) ""
|
||||
string(3) "123" > int(1)
|
||||
string(3) "123" > float(2.5)
|
||||
string(3) "123" > int(0)
|
||||
string(3) "123" <= string(6) "string"
|
||||
string(3) "123" <= string(3) "123"
|
||||
string(3) "123" > string(3) "2.5"
|
||||
string(3) "123" > NULL
|
||||
string(3) "123" <= bool(true)
|
||||
string(3) "123" > bool(false)
|
||||
string(3) "123" <= object(stdClass)#%d (0) {}
|
||||
string(3) "123" <= object(stdClass)#%d (0) {}
|
||||
string(3) "123" <= object(test)#%d (0) {}
|
||||
string(3) "123" <= array(0) {}
|
||||
string(3) "123" > int(-9223372036854775808)
|
||||
string(3) "123" > string(20) "-9223372036854775808"
|
||||
string(3) "2.5" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" > string(0) ""
|
||||
string(3) "2.5" > int(1)
|
||||
string(3) "2.5" <= float(2.5)
|
||||
string(3) "2.5" > int(0)
|
||||
string(3) "2.5" <= string(6) "string"
|
||||
string(3) "2.5" <= string(3) "123"
|
||||
string(3) "2.5" <= string(3) "2.5"
|
||||
string(3) "2.5" > NULL
|
||||
string(3) "2.5" <= bool(true)
|
||||
string(3) "2.5" > bool(false)
|
||||
string(3) "2.5" <= object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" <= object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" <= object(test)#%d (0) {}
|
||||
string(3) "2.5" <= array(0) {}
|
||||
string(3) "2.5" > int(-9223372036854775808)
|
||||
string(3) "2.5" > string(20) "-9223372036854775808"
|
||||
NULL <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL <= string(0) ""
|
||||
NULL <= int(1)
|
||||
NULL <= float(2.5)
|
||||
NULL <= int(0)
|
||||
NULL <= string(6) "string"
|
||||
NULL <= string(3) "123"
|
||||
NULL <= string(3) "2.5"
|
||||
NULL <= NULL
|
||||
NULL <= bool(true)
|
||||
NULL <= bool(false)
|
||||
NULL <= object(stdClass)#%d (0) {}
|
||||
NULL <= object(stdClass)#%d (0) {}
|
||||
NULL <= object(test)#%d (0) {}
|
||||
NULL <= array(0) {}
|
||||
NULL <= int(-9223372036854775808)
|
||||
NULL <= string(20) "-9223372036854775808"
|
||||
bool(true) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) > string(0) ""
|
||||
bool(true) <= int(1)
|
||||
bool(true) <= float(2.5)
|
||||
bool(true) > int(0)
|
||||
bool(true) <= string(6) "string"
|
||||
bool(true) <= string(3) "123"
|
||||
bool(true) <= string(3) "2.5"
|
||||
bool(true) > NULL
|
||||
bool(true) <= bool(true)
|
||||
bool(true) > bool(false)
|
||||
bool(true) <= object(stdClass)#%d (0) {}
|
||||
bool(true) <= object(stdClass)#%d (0) {}
|
||||
bool(true) <= object(test)#%d (0) {}
|
||||
bool(true) > array(0) {}
|
||||
bool(true) <= int(-9223372036854775808)
|
||||
bool(true) <= string(20) "-9223372036854775808"
|
||||
bool(false) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) <= string(0) ""
|
||||
bool(false) <= int(1)
|
||||
bool(false) <= float(2.5)
|
||||
bool(false) <= int(0)
|
||||
bool(false) <= string(6) "string"
|
||||
bool(false) <= string(3) "123"
|
||||
bool(false) <= string(3) "2.5"
|
||||
bool(false) <= NULL
|
||||
bool(false) <= bool(true)
|
||||
bool(false) <= bool(false)
|
||||
bool(false) <= object(stdClass)#%d (0) {}
|
||||
bool(false) <= object(stdClass)#%d (0) {}
|
||||
bool(false) <= object(test)#%d (0) {}
|
||||
bool(false) <= array(0) {}
|
||||
bool(false) <= int(-9223372036854775808)
|
||||
bool(false) <= string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} > string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#%d (0) {} > string(6) "string"
|
||||
object(stdClass)#%d (0) {} > string(3) "123"
|
||||
object(stdClass)#%d (0) {} > string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} > NULL
|
||||
object(stdClass)#%d (0) {} <= bool(true)
|
||||
object(stdClass)#%d (0) {} > bool(false)
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} > string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#%d (0) {} > string(6) "string"
|
||||
object(stdClass)#%d (0) {} > string(3) "123"
|
||||
object(stdClass)#%d (0) {} > string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} > NULL
|
||||
object(stdClass)#%d (0) {} <= bool(true)
|
||||
object(stdClass)#%d (0) {} > bool(false)
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} > string(0) ""
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(test)#%d (0) {} > string(6) "string"
|
||||
object(test)#%d (0) {} > string(3) "123"
|
||||
object(test)#%d (0) {} > string(3) "2.5"
|
||||
object(test)#%d (0) {} > NULL
|
||||
object(test)#%d (0) {} <= bool(true)
|
||||
object(test)#%d (0) {} > bool(false)
|
||||
object(test)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} <= object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} > array(0) {}
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(test)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
array(0) {} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} > string(0) ""
|
||||
array(0) {} > int(1)
|
||||
array(0) {} > float(2.5)
|
||||
array(0) {} > int(0)
|
||||
array(0) {} > string(6) "string"
|
||||
array(0) {} > string(3) "123"
|
||||
array(0) {} > string(3) "2.5"
|
||||
array(0) {} <= NULL
|
||||
array(0) {} <= bool(true)
|
||||
array(0) {} <= bool(false)
|
||||
array(0) {} <= object(stdClass)#%d (0) {}
|
||||
array(0) {} <= object(stdClass)#%d (0) {}
|
||||
array(0) {} <= object(test)#%d (0) {}
|
||||
array(0) {} <= array(0) {}
|
||||
array(0) {} > int(-9223372036854775808)
|
||||
array(0) {} > string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) <= string(0) ""
|
||||
int(-9223372036854775808) <= int(1)
|
||||
int(-9223372036854775808) <= float(2.5)
|
||||
int(-9223372036854775808) <= int(0)
|
||||
int(-9223372036854775808) <= string(6) "string"
|
||||
int(-9223372036854775808) <= string(3) "123"
|
||||
int(-9223372036854775808) <= string(3) "2.5"
|
||||
int(-9223372036854775808) > NULL
|
||||
int(-9223372036854775808) <= bool(true)
|
||||
int(-9223372036854775808) > bool(false)
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(-9223372036854775808) <= array(0) {}
|
||||
int(-9223372036854775808) <= int(-9223372036854775808)
|
||||
int(-9223372036854775808) <= string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" > string(0) ""
|
||||
string(20) "-9223372036854775808" <= int(1)
|
||||
string(20) "-9223372036854775808" <= float(2.5)
|
||||
string(20) "-9223372036854775808" <= int(0)
|
||||
string(20) "-9223372036854775808" <= string(6) "string"
|
||||
string(20) "-9223372036854775808" <= string(3) "123"
|
||||
string(20) "-9223372036854775808" <= string(3) "2.5"
|
||||
string(20) "-9223372036854775808" > NULL
|
||||
string(20) "-9223372036854775808" <= bool(true)
|
||||
string(20) "-9223372036854775808" > bool(false)
|
||||
string(20) "-9223372036854775808" <= object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= array(0) {}
|
||||
string(20) "-9223372036854775808" <= int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" <= string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (less than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var < $a[$i]) ? " < " : " >= ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(11) "-2147483648"
|
||||
string(0) "" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" >= string(0) ""
|
||||
string(0) "" < int(1)
|
||||
string(0) "" < float(2.5)
|
||||
string(0) "" >= int(0)
|
||||
string(0) "" < string(6) "string"
|
||||
string(0) "" < string(3) "123"
|
||||
string(0) "" < string(3) "2.5"
|
||||
string(0) "" >= NULL
|
||||
string(0) "" < bool(true)
|
||||
string(0) "" >= bool(false)
|
||||
string(0) "" < object(stdClass)#1 (0) {}
|
||||
string(0) "" < object(stdClass)#2 (0) {}
|
||||
string(0) "" < object(test)#3 (0) {}
|
||||
string(0) "" < array(0) {}
|
||||
string(0) "" >= int(-2147483648)
|
||||
string(0) "" < string(11) "-2147483648"
|
||||
int(1) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) >= string(0) ""
|
||||
int(1) >= int(1)
|
||||
int(1) < float(2.5)
|
||||
int(1) >= int(0)
|
||||
int(1) >= string(6) "string"
|
||||
int(1) < string(3) "123"
|
||||
int(1) < string(3) "2.5"
|
||||
int(1) >= NULL
|
||||
int(1) >= bool(true)
|
||||
int(1) >= bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#1 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#2 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= object(test)#3 (0) {}
|
||||
int(1) < array(0) {}
|
||||
int(1) >= int(-2147483648)
|
||||
int(1) >= string(11) "-2147483648"
|
||||
float(2.5) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) >= string(0) ""
|
||||
float(2.5) >= int(1)
|
||||
float(2.5) >= float(2.5)
|
||||
float(2.5) >= int(0)
|
||||
float(2.5) >= string(6) "string"
|
||||
float(2.5) < string(3) "123"
|
||||
float(2.5) >= string(3) "2.5"
|
||||
float(2.5) >= NULL
|
||||
float(2.5) >= bool(true)
|
||||
float(2.5) >= bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#1 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#2 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
>= object(test)#3 (0) {}
|
||||
float(2.5) < array(0) {}
|
||||
float(2.5) >= int(-2147483648)
|
||||
float(2.5) >= string(11) "-2147483648"
|
||||
int(0) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) >= string(0) ""
|
||||
int(0) < int(1)
|
||||
int(0) < float(2.5)
|
||||
int(0) >= int(0)
|
||||
int(0) >= string(6) "string"
|
||||
int(0) < string(3) "123"
|
||||
int(0) < string(3) "2.5"
|
||||
int(0) >= NULL
|
||||
int(0) < bool(true)
|
||||
int(0) >= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#1 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#2 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#3 (0) {}
|
||||
int(0) < array(0) {}
|
||||
int(0) >= int(-2147483648)
|
||||
int(0) >= string(11) "-2147483648"
|
||||
string(6) "string" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" >= string(0) ""
|
||||
string(6) "string" < int(1)
|
||||
string(6) "string" < float(2.5)
|
||||
string(6) "string" >= int(0)
|
||||
string(6) "string" >= string(6) "string"
|
||||
string(6) "string" >= string(3) "123"
|
||||
string(6) "string" >= string(3) "2.5"
|
||||
string(6) "string" >= NULL
|
||||
string(6) "string" >= bool(true)
|
||||
string(6) "string" >= bool(false)
|
||||
string(6) "string" < object(stdClass)#1 (0) {}
|
||||
string(6) "string" < object(stdClass)#2 (0) {}
|
||||
string(6) "string" < object(test)#3 (0) {}
|
||||
string(6) "string" < array(0) {}
|
||||
string(6) "string" >= int(-2147483648)
|
||||
string(6) "string" >= string(11) "-2147483648"
|
||||
string(3) "123" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" >= string(0) ""
|
||||
string(3) "123" >= int(1)
|
||||
string(3) "123" >= float(2.5)
|
||||
string(3) "123" >= int(0)
|
||||
string(3) "123" < string(6) "string"
|
||||
string(3) "123" >= string(3) "123"
|
||||
string(3) "123" >= string(3) "2.5"
|
||||
string(3) "123" >= NULL
|
||||
string(3) "123" >= bool(true)
|
||||
string(3) "123" >= bool(false)
|
||||
string(3) "123" < object(stdClass)#1 (0) {}
|
||||
string(3) "123" < object(stdClass)#2 (0) {}
|
||||
string(3) "123" < object(test)#3 (0) {}
|
||||
string(3) "123" < array(0) {}
|
||||
string(3) "123" >= int(-2147483648)
|
||||
string(3) "123" >= string(11) "-2147483648"
|
||||
string(3) "2.5" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" >= string(0) ""
|
||||
string(3) "2.5" >= int(1)
|
||||
string(3) "2.5" >= float(2.5)
|
||||
string(3) "2.5" >= int(0)
|
||||
string(3) "2.5" < string(6) "string"
|
||||
string(3) "2.5" < string(3) "123"
|
||||
string(3) "2.5" >= string(3) "2.5"
|
||||
string(3) "2.5" >= NULL
|
||||
string(3) "2.5" >= bool(true)
|
||||
string(3) "2.5" >= bool(false)
|
||||
string(3) "2.5" < object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" < object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" < object(test)#3 (0) {}
|
||||
string(3) "2.5" < array(0) {}
|
||||
string(3) "2.5" >= int(-2147483648)
|
||||
string(3) "2.5" >= string(11) "-2147483648"
|
||||
NULL < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL >= string(0) ""
|
||||
NULL < int(1)
|
||||
NULL < float(2.5)
|
||||
NULL >= int(0)
|
||||
NULL < string(6) "string"
|
||||
NULL < string(3) "123"
|
||||
NULL < string(3) "2.5"
|
||||
NULL >= NULL
|
||||
NULL < bool(true)
|
||||
NULL >= bool(false)
|
||||
NULL < object(stdClass)#1 (0) {}
|
||||
NULL < object(stdClass)#2 (0) {}
|
||||
NULL < object(test)#3 (0) {}
|
||||
NULL >= array(0) {}
|
||||
NULL < int(-2147483648)
|
||||
NULL < string(11) "-2147483648"
|
||||
bool(true) >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) >= string(0) ""
|
||||
bool(true) >= int(1)
|
||||
bool(true) >= float(2.5)
|
||||
bool(true) >= int(0)
|
||||
bool(true) >= string(6) "string"
|
||||
bool(true) >= string(3) "123"
|
||||
bool(true) >= string(3) "2.5"
|
||||
bool(true) >= NULL
|
||||
bool(true) >= bool(true)
|
||||
bool(true) >= bool(false)
|
||||
bool(true) >= object(stdClass)#1 (0) {}
|
||||
bool(true) >= object(stdClass)#2 (0) {}
|
||||
bool(true) >= object(test)#3 (0) {}
|
||||
bool(true) >= array(0) {}
|
||||
bool(true) >= int(-2147483648)
|
||||
bool(true) >= string(11) "-2147483648"
|
||||
bool(false) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) >= string(0) ""
|
||||
bool(false) < int(1)
|
||||
bool(false) < float(2.5)
|
||||
bool(false) >= int(0)
|
||||
bool(false) < string(6) "string"
|
||||
bool(false) < string(3) "123"
|
||||
bool(false) < string(3) "2.5"
|
||||
bool(false) >= NULL
|
||||
bool(false) < bool(true)
|
||||
bool(false) >= bool(false)
|
||||
bool(false) < object(stdClass)#1 (0) {}
|
||||
bool(false) < object(stdClass)#2 (0) {}
|
||||
bool(false) < object(test)#3 (0) {}
|
||||
bool(false) >= array(0) {}
|
||||
bool(false) < int(-2147483648)
|
||||
bool(false) < string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} >= string(0) ""
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#1 (0) {} >= string(6) "string"
|
||||
object(stdClass)#1 (0) {} >= string(3) "123"
|
||||
object(stdClass)#1 (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} >= NULL
|
||||
object(stdClass)#1 (0) {} >= bool(true)
|
||||
object(stdClass)#1 (0) {} >= bool(false)
|
||||
object(stdClass)#1 (0) {} >= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} >= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} >= object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} >= array(0) {}
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(stdClass)#1 (0) {} >= string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} >= string(0) ""
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#2 (0) {} >= string(6) "string"
|
||||
object(stdClass)#2 (0) {} >= string(3) "123"
|
||||
object(stdClass)#2 (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} >= NULL
|
||||
object(stdClass)#2 (0) {} >= bool(true)
|
||||
object(stdClass)#2 (0) {} >= bool(false)
|
||||
object(stdClass)#2 (0) {} >= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} >= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} >= object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} >= array(0) {}
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(stdClass)#2 (0) {} >= string(11) "-2147483648"
|
||||
object(test)#3 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} >= string(0) ""
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(test)#3 (0) {} >= string(6) "string"
|
||||
object(test)#3 (0) {} >= string(3) "123"
|
||||
object(test)#3 (0) {} >= string(3) "2.5"
|
||||
object(test)#3 (0) {} >= NULL
|
||||
object(test)#3 (0) {} >= bool(true)
|
||||
object(test)#3 (0) {} >= bool(false)
|
||||
object(test)#3 (0) {} >= object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} >= object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} >= object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} >= array(0) {}
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(test)#3 (0) {} >= string(11) "-2147483648"
|
||||
array(0) {} < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} >= string(0) ""
|
||||
array(0) {} >= int(1)
|
||||
array(0) {} >= float(2.5)
|
||||
array(0) {} >= int(0)
|
||||
array(0) {} >= string(6) "string"
|
||||
array(0) {} >= string(3) "123"
|
||||
array(0) {} >= string(3) "2.5"
|
||||
array(0) {} >= NULL
|
||||
array(0) {} < bool(true)
|
||||
array(0) {} >= bool(false)
|
||||
array(0) {} < object(stdClass)#1 (0) {}
|
||||
array(0) {} < object(stdClass)#2 (0) {}
|
||||
array(0) {} < object(test)#3 (0) {}
|
||||
array(0) {} >= array(0) {}
|
||||
array(0) {} >= int(-2147483648)
|
||||
array(0) {} >= string(11) "-2147483648"
|
||||
int(-2147483648) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) < string(0) ""
|
||||
int(-2147483648) < int(1)
|
||||
int(-2147483648) < float(2.5)
|
||||
int(-2147483648) < int(0)
|
||||
int(-2147483648) < string(6) "string"
|
||||
int(-2147483648) < string(3) "123"
|
||||
int(-2147483648) < string(3) "2.5"
|
||||
int(-2147483648) >= NULL
|
||||
int(-2147483648) >= bool(true)
|
||||
int(-2147483648) >= bool(false)
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#1 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#2 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#3 (0) {}
|
||||
int(-2147483648) < array(0) {}
|
||||
int(-2147483648) >= int(-2147483648)
|
||||
int(-2147483648) >= string(11) "-2147483648"
|
||||
string(11) "-2147483648" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" >= string(0) ""
|
||||
string(11) "-2147483648" < int(1)
|
||||
string(11) "-2147483648" < float(2.5)
|
||||
string(11) "-2147483648" < int(0)
|
||||
string(11) "-2147483648" < string(6) "string"
|
||||
string(11) "-2147483648" < string(3) "123"
|
||||
string(11) "-2147483648" < string(3) "2.5"
|
||||
string(11) "-2147483648" >= NULL
|
||||
string(11) "-2147483648" >= bool(true)
|
||||
string(11) "-2147483648" >= bool(false)
|
||||
string(11) "-2147483648" < object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" < object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" < object(test)#3 (0) {}
|
||||
string(11) "-2147483648" < array(0) {}
|
||||
string(11) "-2147483648" >= int(-2147483648)
|
||||
string(11) "-2147483648" >= string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (less than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var < $a[$i]) ? " < " : " >= ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(20) "-9223372036854775808"
|
||||
string(0) "" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" >= string(0) ""
|
||||
string(0) "" < int(1)
|
||||
string(0) "" < float(2.5)
|
||||
string(0) "" >= int(0)
|
||||
string(0) "" < string(6) "string"
|
||||
string(0) "" < string(3) "123"
|
||||
string(0) "" < string(3) "2.5"
|
||||
string(0) "" >= NULL
|
||||
string(0) "" < bool(true)
|
||||
string(0) "" >= bool(false)
|
||||
string(0) "" < object(stdClass)#%d (0) {}
|
||||
string(0) "" < object(stdClass)#%d (0) {}
|
||||
string(0) "" < object(test)#%d (0) {}
|
||||
string(0) "" < array(0) {}
|
||||
string(0) "" >= int(-9223372036854775808)
|
||||
string(0) "" < string(20) "-9223372036854775808"
|
||||
int(1) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) >= string(0) ""
|
||||
int(1) >= int(1)
|
||||
int(1) < float(2.5)
|
||||
int(1) >= int(0)
|
||||
int(1) >= string(6) "string"
|
||||
int(1) < string(3) "123"
|
||||
int(1) < string(3) "2.5"
|
||||
int(1) >= NULL
|
||||
int(1) >= bool(true)
|
||||
int(1) >= bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= object(test)#%d (0) {}
|
||||
int(1) < array(0) {}
|
||||
int(1) >= int(-9223372036854775808)
|
||||
int(1) >= string(20) "-9223372036854775808"
|
||||
float(2.5) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) >= string(0) ""
|
||||
float(2.5) >= int(1)
|
||||
float(2.5) >= float(2.5)
|
||||
float(2.5) >= int(0)
|
||||
float(2.5) >= string(6) "string"
|
||||
float(2.5) < string(3) "123"
|
||||
float(2.5) >= string(3) "2.5"
|
||||
float(2.5) >= NULL
|
||||
float(2.5) >= bool(true)
|
||||
float(2.5) >= bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
>= object(test)#%d (0) {}
|
||||
float(2.5) < array(0) {}
|
||||
float(2.5) >= int(-9223372036854775808)
|
||||
float(2.5) >= string(20) "-9223372036854775808"
|
||||
int(0) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) >= string(0) ""
|
||||
int(0) < int(1)
|
||||
int(0) < float(2.5)
|
||||
int(0) >= int(0)
|
||||
int(0) >= string(6) "string"
|
||||
int(0) < string(3) "123"
|
||||
int(0) < string(3) "2.5"
|
||||
int(0) >= NULL
|
||||
int(0) < bool(true)
|
||||
int(0) >= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#%d (0) {}
|
||||
int(0) < array(0) {}
|
||||
int(0) >= int(-9223372036854775808)
|
||||
int(0) >= string(20) "-9223372036854775808"
|
||||
string(6) "string" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" >= string(0) ""
|
||||
string(6) "string" < int(1)
|
||||
string(6) "string" < float(2.5)
|
||||
string(6) "string" >= int(0)
|
||||
string(6) "string" >= string(6) "string"
|
||||
string(6) "string" >= string(3) "123"
|
||||
string(6) "string" >= string(3) "2.5"
|
||||
string(6) "string" >= NULL
|
||||
string(6) "string" >= bool(true)
|
||||
string(6) "string" >= bool(false)
|
||||
string(6) "string" < object(stdClass)#%d (0) {}
|
||||
string(6) "string" < object(stdClass)#%d (0) {}
|
||||
string(6) "string" < object(test)#%d (0) {}
|
||||
string(6) "string" < array(0) {}
|
||||
string(6) "string" >= int(-9223372036854775808)
|
||||
string(6) "string" >= string(20) "-9223372036854775808"
|
||||
string(3) "123" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" >= string(0) ""
|
||||
string(3) "123" >= int(1)
|
||||
string(3) "123" >= float(2.5)
|
||||
string(3) "123" >= int(0)
|
||||
string(3) "123" < string(6) "string"
|
||||
string(3) "123" >= string(3) "123"
|
||||
string(3) "123" >= string(3) "2.5"
|
||||
string(3) "123" >= NULL
|
||||
string(3) "123" >= bool(true)
|
||||
string(3) "123" >= bool(false)
|
||||
string(3) "123" < object(stdClass)#%d (0) {}
|
||||
string(3) "123" < object(stdClass)#%d (0) {}
|
||||
string(3) "123" < object(test)#%d (0) {}
|
||||
string(3) "123" < array(0) {}
|
||||
string(3) "123" >= int(-9223372036854775808)
|
||||
string(3) "123" >= string(20) "-9223372036854775808"
|
||||
string(3) "2.5" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" >= string(0) ""
|
||||
string(3) "2.5" >= int(1)
|
||||
string(3) "2.5" >= float(2.5)
|
||||
string(3) "2.5" >= int(0)
|
||||
string(3) "2.5" < string(6) "string"
|
||||
string(3) "2.5" < string(3) "123"
|
||||
string(3) "2.5" >= string(3) "2.5"
|
||||
string(3) "2.5" >= NULL
|
||||
string(3) "2.5" >= bool(true)
|
||||
string(3) "2.5" >= bool(false)
|
||||
string(3) "2.5" < object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" < object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" < object(test)#%d (0) {}
|
||||
string(3) "2.5" < array(0) {}
|
||||
string(3) "2.5" >= int(-9223372036854775808)
|
||||
string(3) "2.5" >= string(20) "-9223372036854775808"
|
||||
NULL < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL >= string(0) ""
|
||||
NULL < int(1)
|
||||
NULL < float(2.5)
|
||||
NULL >= int(0)
|
||||
NULL < string(6) "string"
|
||||
NULL < string(3) "123"
|
||||
NULL < string(3) "2.5"
|
||||
NULL >= NULL
|
||||
NULL < bool(true)
|
||||
NULL >= bool(false)
|
||||
NULL < object(stdClass)#%d (0) {}
|
||||
NULL < object(stdClass)#%d (0) {}
|
||||
NULL < object(test)#%d (0) {}
|
||||
NULL >= array(0) {}
|
||||
NULL < int(-9223372036854775808)
|
||||
NULL < string(20) "-9223372036854775808"
|
||||
bool(true) >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) >= string(0) ""
|
||||
bool(true) >= int(1)
|
||||
bool(true) >= float(2.5)
|
||||
bool(true) >= int(0)
|
||||
bool(true) >= string(6) "string"
|
||||
bool(true) >= string(3) "123"
|
||||
bool(true) >= string(3) "2.5"
|
||||
bool(true) >= NULL
|
||||
bool(true) >= bool(true)
|
||||
bool(true) >= bool(false)
|
||||
bool(true) >= object(stdClass)#%d (0) {}
|
||||
bool(true) >= object(stdClass)#%d (0) {}
|
||||
bool(true) >= object(test)#%d (0) {}
|
||||
bool(true) >= array(0) {}
|
||||
bool(true) >= int(-9223372036854775808)
|
||||
bool(true) >= string(20) "-9223372036854775808"
|
||||
bool(false) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) >= string(0) ""
|
||||
bool(false) < int(1)
|
||||
bool(false) < float(2.5)
|
||||
bool(false) >= int(0)
|
||||
bool(false) < string(6) "string"
|
||||
bool(false) < string(3) "123"
|
||||
bool(false) < string(3) "2.5"
|
||||
bool(false) >= NULL
|
||||
bool(false) < bool(true)
|
||||
bool(false) >= bool(false)
|
||||
bool(false) < object(stdClass)#%d (0) {}
|
||||
bool(false) < object(stdClass)#%d (0) {}
|
||||
bool(false) < object(test)#%d (0) {}
|
||||
bool(false) >= array(0) {}
|
||||
bool(false) < int(-9223372036854775808)
|
||||
bool(false) < string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} >= string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#%d (0) {} >= string(6) "string"
|
||||
object(stdClass)#%d (0) {} >= string(3) "123"
|
||||
object(stdClass)#%d (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} >= NULL
|
||||
object(stdClass)#%d (0) {} >= bool(true)
|
||||
object(stdClass)#%d (0) {} >= bool(false)
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} >= string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#%d (0) {} >= string(6) "string"
|
||||
object(stdClass)#%d (0) {} >= string(3) "123"
|
||||
object(stdClass)#%d (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} >= NULL
|
||||
object(stdClass)#%d (0) {} >= bool(true)
|
||||
object(stdClass)#%d (0) {} >= bool(false)
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} >= string(0) ""
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(test)#%d (0) {} >= string(6) "string"
|
||||
object(test)#%d (0) {} >= string(3) "123"
|
||||
object(test)#%d (0) {} >= string(3) "2.5"
|
||||
object(test)#%d (0) {} >= NULL
|
||||
object(test)#%d (0) {} >= bool(true)
|
||||
object(test)#%d (0) {} >= bool(false)
|
||||
object(test)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} >= object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} >= array(0) {}
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(test)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
array(0) {} < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} >= string(0) ""
|
||||
array(0) {} >= int(1)
|
||||
array(0) {} >= float(2.5)
|
||||
array(0) {} >= int(0)
|
||||
array(0) {} >= string(6) "string"
|
||||
array(0) {} >= string(3) "123"
|
||||
array(0) {} >= string(3) "2.5"
|
||||
array(0) {} >= NULL
|
||||
array(0) {} < bool(true)
|
||||
array(0) {} >= bool(false)
|
||||
array(0) {} < object(stdClass)#%d (0) {}
|
||||
array(0) {} < object(stdClass)#%d (0) {}
|
||||
array(0) {} < object(test)#%d (0) {}
|
||||
array(0) {} >= array(0) {}
|
||||
array(0) {} >= int(-9223372036854775808)
|
||||
array(0) {} >= string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) < string(0) ""
|
||||
int(-9223372036854775808) < int(1)
|
||||
int(-9223372036854775808) < float(2.5)
|
||||
int(-9223372036854775808) < int(0)
|
||||
int(-9223372036854775808) < string(6) "string"
|
||||
int(-9223372036854775808) < string(3) "123"
|
||||
int(-9223372036854775808) < string(3) "2.5"
|
||||
int(-9223372036854775808) >= NULL
|
||||
int(-9223372036854775808) >= bool(true)
|
||||
int(-9223372036854775808) >= bool(false)
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#%d (0) {}
|
||||
int(-9223372036854775808) < array(0) {}
|
||||
int(-9223372036854775808) >= int(-9223372036854775808)
|
||||
int(-9223372036854775808) >= string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" >= string(0) ""
|
||||
string(20) "-9223372036854775808" < int(1)
|
||||
string(20) "-9223372036854775808" < float(2.5)
|
||||
string(20) "-9223372036854775808" < int(0)
|
||||
string(20) "-9223372036854775808" < string(6) "string"
|
||||
string(20) "-9223372036854775808" < string(3) "123"
|
||||
string(20) "-9223372036854775808" < string(3) "2.5"
|
||||
string(20) "-9223372036854775808" >= NULL
|
||||
string(20) "-9223372036854775808" >= bool(true)
|
||||
string(20) "-9223372036854775808" >= bool(false)
|
||||
string(20) "-9223372036854775808" < object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < array(0) {}
|
||||
string(20) "-9223372036854775808" >= int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" >= string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (greater or equal than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var >= $a[$i]) ? " >= " : " < ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(11) "-2147483648"
|
||||
string(0) "" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" >= string(0) ""
|
||||
string(0) "" < int(1)
|
||||
string(0) "" < float(2.5)
|
||||
string(0) "" >= int(0)
|
||||
string(0) "" < string(6) "string"
|
||||
string(0) "" < string(3) "123"
|
||||
string(0) "" < string(3) "2.5"
|
||||
string(0) "" >= NULL
|
||||
string(0) "" < bool(true)
|
||||
string(0) "" >= bool(false)
|
||||
string(0) "" < object(stdClass)#1 (0) {}
|
||||
string(0) "" < object(stdClass)#2 (0) {}
|
||||
string(0) "" < object(test)#3 (0) {}
|
||||
string(0) "" < array(0) {}
|
||||
string(0) "" >= int(-2147483648)
|
||||
string(0) "" < string(11) "-2147483648"
|
||||
int(1) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) >= string(0) ""
|
||||
int(1) >= int(1)
|
||||
int(1) < float(2.5)
|
||||
int(1) >= int(0)
|
||||
int(1) >= string(6) "string"
|
||||
int(1) < string(3) "123"
|
||||
int(1) < string(3) "2.5"
|
||||
int(1) >= NULL
|
||||
int(1) >= bool(true)
|
||||
int(1) >= bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#1 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#2 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= object(test)#3 (0) {}
|
||||
int(1) < array(0) {}
|
||||
int(1) >= int(-2147483648)
|
||||
int(1) >= string(11) "-2147483648"
|
||||
float(2.5) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) >= string(0) ""
|
||||
float(2.5) >= int(1)
|
||||
float(2.5) >= float(2.5)
|
||||
float(2.5) >= int(0)
|
||||
float(2.5) >= string(6) "string"
|
||||
float(2.5) < string(3) "123"
|
||||
float(2.5) >= string(3) "2.5"
|
||||
float(2.5) >= NULL
|
||||
float(2.5) >= bool(true)
|
||||
float(2.5) >= bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#1 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#2 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
>= object(test)#3 (0) {}
|
||||
float(2.5) < array(0) {}
|
||||
float(2.5) >= int(-2147483648)
|
||||
float(2.5) >= string(11) "-2147483648"
|
||||
int(0) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) >= string(0) ""
|
||||
int(0) < int(1)
|
||||
int(0) < float(2.5)
|
||||
int(0) >= int(0)
|
||||
int(0) >= string(6) "string"
|
||||
int(0) < string(3) "123"
|
||||
int(0) < string(3) "2.5"
|
||||
int(0) >= NULL
|
||||
int(0) < bool(true)
|
||||
int(0) >= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#1 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#2 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#3 (0) {}
|
||||
int(0) < array(0) {}
|
||||
int(0) >= int(-2147483648)
|
||||
int(0) >= string(11) "-2147483648"
|
||||
string(6) "string" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" >= string(0) ""
|
||||
string(6) "string" < int(1)
|
||||
string(6) "string" < float(2.5)
|
||||
string(6) "string" >= int(0)
|
||||
string(6) "string" >= string(6) "string"
|
||||
string(6) "string" >= string(3) "123"
|
||||
string(6) "string" >= string(3) "2.5"
|
||||
string(6) "string" >= NULL
|
||||
string(6) "string" >= bool(true)
|
||||
string(6) "string" >= bool(false)
|
||||
string(6) "string" < object(stdClass)#1 (0) {}
|
||||
string(6) "string" < object(stdClass)#2 (0) {}
|
||||
string(6) "string" < object(test)#3 (0) {}
|
||||
string(6) "string" < array(0) {}
|
||||
string(6) "string" >= int(-2147483648)
|
||||
string(6) "string" >= string(11) "-2147483648"
|
||||
string(3) "123" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" >= string(0) ""
|
||||
string(3) "123" >= int(1)
|
||||
string(3) "123" >= float(2.5)
|
||||
string(3) "123" >= int(0)
|
||||
string(3) "123" < string(6) "string"
|
||||
string(3) "123" >= string(3) "123"
|
||||
string(3) "123" >= string(3) "2.5"
|
||||
string(3) "123" >= NULL
|
||||
string(3) "123" >= bool(true)
|
||||
string(3) "123" >= bool(false)
|
||||
string(3) "123" < object(stdClass)#1 (0) {}
|
||||
string(3) "123" < object(stdClass)#2 (0) {}
|
||||
string(3) "123" < object(test)#3 (0) {}
|
||||
string(3) "123" < array(0) {}
|
||||
string(3) "123" >= int(-2147483648)
|
||||
string(3) "123" >= string(11) "-2147483648"
|
||||
string(3) "2.5" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" >= string(0) ""
|
||||
string(3) "2.5" >= int(1)
|
||||
string(3) "2.5" >= float(2.5)
|
||||
string(3) "2.5" >= int(0)
|
||||
string(3) "2.5" < string(6) "string"
|
||||
string(3) "2.5" < string(3) "123"
|
||||
string(3) "2.5" >= string(3) "2.5"
|
||||
string(3) "2.5" >= NULL
|
||||
string(3) "2.5" >= bool(true)
|
||||
string(3) "2.5" >= bool(false)
|
||||
string(3) "2.5" < object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" < object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" < object(test)#3 (0) {}
|
||||
string(3) "2.5" < array(0) {}
|
||||
string(3) "2.5" >= int(-2147483648)
|
||||
string(3) "2.5" >= string(11) "-2147483648"
|
||||
NULL < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL >= string(0) ""
|
||||
NULL < int(1)
|
||||
NULL < float(2.5)
|
||||
NULL >= int(0)
|
||||
NULL < string(6) "string"
|
||||
NULL < string(3) "123"
|
||||
NULL < string(3) "2.5"
|
||||
NULL >= NULL
|
||||
NULL < bool(true)
|
||||
NULL >= bool(false)
|
||||
NULL < object(stdClass)#1 (0) {}
|
||||
NULL < object(stdClass)#2 (0) {}
|
||||
NULL < object(test)#3 (0) {}
|
||||
NULL >= array(0) {}
|
||||
NULL < int(-2147483648)
|
||||
NULL < string(11) "-2147483648"
|
||||
bool(true) >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) >= string(0) ""
|
||||
bool(true) >= int(1)
|
||||
bool(true) >= float(2.5)
|
||||
bool(true) >= int(0)
|
||||
bool(true) >= string(6) "string"
|
||||
bool(true) >= string(3) "123"
|
||||
bool(true) >= string(3) "2.5"
|
||||
bool(true) >= NULL
|
||||
bool(true) >= bool(true)
|
||||
bool(true) >= bool(false)
|
||||
bool(true) >= object(stdClass)#1 (0) {}
|
||||
bool(true) >= object(stdClass)#2 (0) {}
|
||||
bool(true) >= object(test)#3 (0) {}
|
||||
bool(true) >= array(0) {}
|
||||
bool(true) >= int(-2147483648)
|
||||
bool(true) >= string(11) "-2147483648"
|
||||
bool(false) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) >= string(0) ""
|
||||
bool(false) < int(1)
|
||||
bool(false) < float(2.5)
|
||||
bool(false) >= int(0)
|
||||
bool(false) < string(6) "string"
|
||||
bool(false) < string(3) "123"
|
||||
bool(false) < string(3) "2.5"
|
||||
bool(false) >= NULL
|
||||
bool(false) < bool(true)
|
||||
bool(false) >= bool(false)
|
||||
bool(false) < object(stdClass)#1 (0) {}
|
||||
bool(false) < object(stdClass)#2 (0) {}
|
||||
bool(false) < object(test)#3 (0) {}
|
||||
bool(false) >= array(0) {}
|
||||
bool(false) < int(-2147483648)
|
||||
bool(false) < string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} >= string(0) ""
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#1 (0) {} >= string(6) "string"
|
||||
object(stdClass)#1 (0) {} >= string(3) "123"
|
||||
object(stdClass)#1 (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} >= NULL
|
||||
object(stdClass)#1 (0) {} >= bool(true)
|
||||
object(stdClass)#1 (0) {} >= bool(false)
|
||||
object(stdClass)#1 (0) {} >= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} >= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} < object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} >= array(0) {}
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(stdClass)#1 (0) {} >= string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} >= string(0) ""
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#2 (0) {} >= string(6) "string"
|
||||
object(stdClass)#2 (0) {} >= string(3) "123"
|
||||
object(stdClass)#2 (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} >= NULL
|
||||
object(stdClass)#2 (0) {} >= bool(true)
|
||||
object(stdClass)#2 (0) {} >= bool(false)
|
||||
object(stdClass)#2 (0) {} >= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} >= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} < object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} >= array(0) {}
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(stdClass)#2 (0) {} >= string(11) "-2147483648"
|
||||
object(test)#3 (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} >= string(0) ""
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(test)#3 (0) {} >= string(6) "string"
|
||||
object(test)#3 (0) {} >= string(3) "123"
|
||||
object(test)#3 (0) {} >= string(3) "2.5"
|
||||
object(test)#3 (0) {} >= NULL
|
||||
object(test)#3 (0) {} >= bool(true)
|
||||
object(test)#3 (0) {} >= bool(false)
|
||||
object(test)#3 (0) {} < object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} < object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} >= object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} >= array(0) {}
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(-2147483648)
|
||||
object(test)#3 (0) {} >= string(11) "-2147483648"
|
||||
array(0) {} < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} >= string(0) ""
|
||||
array(0) {} >= int(1)
|
||||
array(0) {} >= float(2.5)
|
||||
array(0) {} >= int(0)
|
||||
array(0) {} >= string(6) "string"
|
||||
array(0) {} >= string(3) "123"
|
||||
array(0) {} >= string(3) "2.5"
|
||||
array(0) {} >= NULL
|
||||
array(0) {} < bool(true)
|
||||
array(0) {} >= bool(false)
|
||||
array(0) {} < object(stdClass)#1 (0) {}
|
||||
array(0) {} < object(stdClass)#2 (0) {}
|
||||
array(0) {} < object(test)#3 (0) {}
|
||||
array(0) {} >= array(0) {}
|
||||
array(0) {} >= int(-2147483648)
|
||||
array(0) {} >= string(11) "-2147483648"
|
||||
int(-2147483648) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) < string(0) ""
|
||||
int(-2147483648) < int(1)
|
||||
int(-2147483648) < float(2.5)
|
||||
int(-2147483648) < int(0)
|
||||
int(-2147483648) < string(6) "string"
|
||||
int(-2147483648) < string(3) "123"
|
||||
int(-2147483648) < string(3) "2.5"
|
||||
int(-2147483648) >= NULL
|
||||
int(-2147483648) >= bool(true)
|
||||
int(-2147483648) >= bool(false)
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#1 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#2 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#3 (0) {}
|
||||
int(-2147483648) < array(0) {}
|
||||
int(-2147483648) >= int(-2147483648)
|
||||
int(-2147483648) >= string(11) "-2147483648"
|
||||
string(11) "-2147483648" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" >= string(0) ""
|
||||
string(11) "-2147483648" < int(1)
|
||||
string(11) "-2147483648" < float(2.5)
|
||||
string(11) "-2147483648" < int(0)
|
||||
string(11) "-2147483648" < string(6) "string"
|
||||
string(11) "-2147483648" < string(3) "123"
|
||||
string(11) "-2147483648" < string(3) "2.5"
|
||||
string(11) "-2147483648" >= NULL
|
||||
string(11) "-2147483648" >= bool(true)
|
||||
string(11) "-2147483648" >= bool(false)
|
||||
string(11) "-2147483648" < object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" < object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" < object(test)#3 (0) {}
|
||||
string(11) "-2147483648" < array(0) {}
|
||||
string(11) "-2147483648" >= int(-2147483648)
|
||||
string(11) "-2147483648" >= string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (greater or equal than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var >= $a[$i]) ? " >= " : " < ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} < object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} >= string(20) "-9223372036854775808"
|
||||
string(0) "" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" >= string(0) ""
|
||||
string(0) "" < int(1)
|
||||
string(0) "" < float(2.5)
|
||||
string(0) "" >= int(0)
|
||||
string(0) "" < string(6) "string"
|
||||
string(0) "" < string(3) "123"
|
||||
string(0) "" < string(3) "2.5"
|
||||
string(0) "" >= NULL
|
||||
string(0) "" < bool(true)
|
||||
string(0) "" >= bool(false)
|
||||
string(0) "" < object(stdClass)#%d (0) {}
|
||||
string(0) "" < object(stdClass)#%d (0) {}
|
||||
string(0) "" < object(test)#%d (0) {}
|
||||
string(0) "" < array(0) {}
|
||||
string(0) "" >= int(-9223372036854775808)
|
||||
string(0) "" < string(20) "-9223372036854775808"
|
||||
int(1) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) >= string(0) ""
|
||||
int(1) >= int(1)
|
||||
int(1) < float(2.5)
|
||||
int(1) >= int(0)
|
||||
int(1) >= string(6) "string"
|
||||
int(1) < string(3) "123"
|
||||
int(1) < string(3) "2.5"
|
||||
int(1) >= NULL
|
||||
int(1) >= bool(true)
|
||||
int(1) >= bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= object(test)#%d (0) {}
|
||||
int(1) < array(0) {}
|
||||
int(1) >= int(-9223372036854775808)
|
||||
int(1) >= string(20) "-9223372036854775808"
|
||||
float(2.5) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) >= string(0) ""
|
||||
float(2.5) >= int(1)
|
||||
float(2.5) >= float(2.5)
|
||||
float(2.5) >= int(0)
|
||||
float(2.5) >= string(6) "string"
|
||||
float(2.5) < string(3) "123"
|
||||
float(2.5) >= string(3) "2.5"
|
||||
float(2.5) >= NULL
|
||||
float(2.5) >= bool(true)
|
||||
float(2.5) >= bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
>= object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
>= object(test)#%d (0) {}
|
||||
float(2.5) < array(0) {}
|
||||
float(2.5) >= int(-9223372036854775808)
|
||||
float(2.5) >= string(20) "-9223372036854775808"
|
||||
int(0) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) >= string(0) ""
|
||||
int(0) < int(1)
|
||||
int(0) < float(2.5)
|
||||
int(0) >= int(0)
|
||||
int(0) >= string(6) "string"
|
||||
int(0) < string(3) "123"
|
||||
int(0) < string(3) "2.5"
|
||||
int(0) >= NULL
|
||||
int(0) < bool(true)
|
||||
int(0) >= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#%d (0) {}
|
||||
int(0) < array(0) {}
|
||||
int(0) >= int(-9223372036854775808)
|
||||
int(0) >= string(20) "-9223372036854775808"
|
||||
string(6) "string" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" >= string(0) ""
|
||||
string(6) "string" < int(1)
|
||||
string(6) "string" < float(2.5)
|
||||
string(6) "string" >= int(0)
|
||||
string(6) "string" >= string(6) "string"
|
||||
string(6) "string" >= string(3) "123"
|
||||
string(6) "string" >= string(3) "2.5"
|
||||
string(6) "string" >= NULL
|
||||
string(6) "string" >= bool(true)
|
||||
string(6) "string" >= bool(false)
|
||||
string(6) "string" < object(stdClass)#%d (0) {}
|
||||
string(6) "string" < object(stdClass)#%d (0) {}
|
||||
string(6) "string" < object(test)#%d (0) {}
|
||||
string(6) "string" < array(0) {}
|
||||
string(6) "string" >= int(-9223372036854775808)
|
||||
string(6) "string" >= string(20) "-9223372036854775808"
|
||||
string(3) "123" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" >= string(0) ""
|
||||
string(3) "123" >= int(1)
|
||||
string(3) "123" >= float(2.5)
|
||||
string(3) "123" >= int(0)
|
||||
string(3) "123" < string(6) "string"
|
||||
string(3) "123" >= string(3) "123"
|
||||
string(3) "123" >= string(3) "2.5"
|
||||
string(3) "123" >= NULL
|
||||
string(3) "123" >= bool(true)
|
||||
string(3) "123" >= bool(false)
|
||||
string(3) "123" < object(stdClass)#%d (0) {}
|
||||
string(3) "123" < object(stdClass)#%d (0) {}
|
||||
string(3) "123" < object(test)#%d (0) {}
|
||||
string(3) "123" < array(0) {}
|
||||
string(3) "123" >= int(-9223372036854775808)
|
||||
string(3) "123" >= string(20) "-9223372036854775808"
|
||||
string(3) "2.5" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" >= string(0) ""
|
||||
string(3) "2.5" >= int(1)
|
||||
string(3) "2.5" >= float(2.5)
|
||||
string(3) "2.5" >= int(0)
|
||||
string(3) "2.5" < string(6) "string"
|
||||
string(3) "2.5" < string(3) "123"
|
||||
string(3) "2.5" >= string(3) "2.5"
|
||||
string(3) "2.5" >= NULL
|
||||
string(3) "2.5" >= bool(true)
|
||||
string(3) "2.5" >= bool(false)
|
||||
string(3) "2.5" < object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" < object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" < object(test)#%d (0) {}
|
||||
string(3) "2.5" < array(0) {}
|
||||
string(3) "2.5" >= int(-9223372036854775808)
|
||||
string(3) "2.5" >= string(20) "-9223372036854775808"
|
||||
NULL < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL >= string(0) ""
|
||||
NULL < int(1)
|
||||
NULL < float(2.5)
|
||||
NULL >= int(0)
|
||||
NULL < string(6) "string"
|
||||
NULL < string(3) "123"
|
||||
NULL < string(3) "2.5"
|
||||
NULL >= NULL
|
||||
NULL < bool(true)
|
||||
NULL >= bool(false)
|
||||
NULL < object(stdClass)#%d (0) {}
|
||||
NULL < object(stdClass)#%d (0) {}
|
||||
NULL < object(test)#%d (0) {}
|
||||
NULL >= array(0) {}
|
||||
NULL < int(-9223372036854775808)
|
||||
NULL < string(20) "-9223372036854775808"
|
||||
bool(true) >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) >= string(0) ""
|
||||
bool(true) >= int(1)
|
||||
bool(true) >= float(2.5)
|
||||
bool(true) >= int(0)
|
||||
bool(true) >= string(6) "string"
|
||||
bool(true) >= string(3) "123"
|
||||
bool(true) >= string(3) "2.5"
|
||||
bool(true) >= NULL
|
||||
bool(true) >= bool(true)
|
||||
bool(true) >= bool(false)
|
||||
bool(true) >= object(stdClass)#%d (0) {}
|
||||
bool(true) >= object(stdClass)#%d (0) {}
|
||||
bool(true) >= object(test)#%d (0) {}
|
||||
bool(true) >= array(0) {}
|
||||
bool(true) >= int(-9223372036854775808)
|
||||
bool(true) >= string(20) "-9223372036854775808"
|
||||
bool(false) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) >= string(0) ""
|
||||
bool(false) < int(1)
|
||||
bool(false) < float(2.5)
|
||||
bool(false) >= int(0)
|
||||
bool(false) < string(6) "string"
|
||||
bool(false) < string(3) "123"
|
||||
bool(false) < string(3) "2.5"
|
||||
bool(false) >= NULL
|
||||
bool(false) < bool(true)
|
||||
bool(false) >= bool(false)
|
||||
bool(false) < object(stdClass)#%d (0) {}
|
||||
bool(false) < object(stdClass)#%d (0) {}
|
||||
bool(false) < object(test)#%d (0) {}
|
||||
bool(false) >= array(0) {}
|
||||
bool(false) < int(-9223372036854775808)
|
||||
bool(false) < string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} >= string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#%d (0) {} >= string(6) "string"
|
||||
object(stdClass)#%d (0) {} >= string(3) "123"
|
||||
object(stdClass)#%d (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} >= NULL
|
||||
object(stdClass)#%d (0) {} >= bool(true)
|
||||
object(stdClass)#%d (0) {} >= bool(false)
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} < object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} >= string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(stdClass)#%d (0) {} >= string(6) "string"
|
||||
object(stdClass)#%d (0) {} >= string(3) "123"
|
||||
object(stdClass)#%d (0) {} >= string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} >= NULL
|
||||
object(stdClass)#%d (0) {} >= bool(true)
|
||||
object(stdClass)#%d (0) {} >= bool(false)
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} < object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} >= array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} >= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} >= string(0) ""
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(1)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
< float(2.5)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(0)
|
||||
object(test)#%d (0) {} >= string(6) "string"
|
||||
object(test)#%d (0) {} >= string(3) "123"
|
||||
object(test)#%d (0) {} >= string(3) "2.5"
|
||||
object(test)#%d (0) {} >= NULL
|
||||
object(test)#%d (0) {} >= bool(true)
|
||||
object(test)#%d (0) {} >= bool(false)
|
||||
object(test)#%d (0) {} < object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} < object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} >= object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} >= array(0) {}
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
>= int(-9223372036854775808)
|
||||
object(test)#%d (0) {} >= string(20) "-9223372036854775808"
|
||||
array(0) {} < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} >= string(0) ""
|
||||
array(0) {} >= int(1)
|
||||
array(0) {} >= float(2.5)
|
||||
array(0) {} >= int(0)
|
||||
array(0) {} >= string(6) "string"
|
||||
array(0) {} >= string(3) "123"
|
||||
array(0) {} >= string(3) "2.5"
|
||||
array(0) {} >= NULL
|
||||
array(0) {} < bool(true)
|
||||
array(0) {} >= bool(false)
|
||||
array(0) {} < object(stdClass)#%d (0) {}
|
||||
array(0) {} < object(stdClass)#%d (0) {}
|
||||
array(0) {} < object(test)#%d (0) {}
|
||||
array(0) {} >= array(0) {}
|
||||
array(0) {} >= int(-9223372036854775808)
|
||||
array(0) {} >= string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) < string(0) ""
|
||||
int(-9223372036854775808) < int(1)
|
||||
int(-9223372036854775808) < float(2.5)
|
||||
int(-9223372036854775808) < int(0)
|
||||
int(-9223372036854775808) < string(6) "string"
|
||||
int(-9223372036854775808) < string(3) "123"
|
||||
int(-9223372036854775808) < string(3) "2.5"
|
||||
int(-9223372036854775808) >= NULL
|
||||
int(-9223372036854775808) >= bool(true)
|
||||
int(-9223372036854775808) >= bool(false)
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
< object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
< object(test)#%d (0) {}
|
||||
int(-9223372036854775808) < array(0) {}
|
||||
int(-9223372036854775808) >= int(-9223372036854775808)
|
||||
int(-9223372036854775808) >= string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" < array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" >= string(0) ""
|
||||
string(20) "-9223372036854775808" < int(1)
|
||||
string(20) "-9223372036854775808" < float(2.5)
|
||||
string(20) "-9223372036854775808" < int(0)
|
||||
string(20) "-9223372036854775808" < string(6) "string"
|
||||
string(20) "-9223372036854775808" < string(3) "123"
|
||||
string(20) "-9223372036854775808" < string(3) "2.5"
|
||||
string(20) "-9223372036854775808" >= NULL
|
||||
string(20) "-9223372036854775808" >= bool(true)
|
||||
string(20) "-9223372036854775808" >= bool(false)
|
||||
string(20) "-9223372036854775808" < object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" < array(0) {}
|
||||
string(20) "-9223372036854775808" >= int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" >= string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (smaller or equal than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var <= $a[$i]) ? " <= " : " > ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#1 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#2 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(test)#3 (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(-2147483648)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(11) "-2147483648"
|
||||
string(0) "" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" <= string(0) ""
|
||||
string(0) "" <= int(1)
|
||||
string(0) "" <= float(2.5)
|
||||
string(0) "" <= int(0)
|
||||
string(0) "" <= string(6) "string"
|
||||
string(0) "" <= string(3) "123"
|
||||
string(0) "" <= string(3) "2.5"
|
||||
string(0) "" <= NULL
|
||||
string(0) "" <= bool(true)
|
||||
string(0) "" <= bool(false)
|
||||
string(0) "" <= object(stdClass)#1 (0) {}
|
||||
string(0) "" <= object(stdClass)#2 (0) {}
|
||||
string(0) "" <= object(test)#3 (0) {}
|
||||
string(0) "" <= array(0) {}
|
||||
string(0) "" > int(-2147483648)
|
||||
string(0) "" <= string(11) "-2147483648"
|
||||
int(1) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) > string(0) ""
|
||||
int(1) <= int(1)
|
||||
int(1) <= float(2.5)
|
||||
int(1) > int(0)
|
||||
int(1) > string(6) "string"
|
||||
int(1) <= string(3) "123"
|
||||
int(1) <= string(3) "2.5"
|
||||
int(1) > NULL
|
||||
int(1) <= bool(true)
|
||||
int(1) > bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(1) <= array(0) {}
|
||||
int(1) > int(-2147483648)
|
||||
int(1) > string(11) "-2147483648"
|
||||
float(2.5) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) > string(0) ""
|
||||
float(2.5) > int(1)
|
||||
float(2.5) <= float(2.5)
|
||||
float(2.5) > int(0)
|
||||
float(2.5) > string(6) "string"
|
||||
float(2.5) <= string(3) "123"
|
||||
float(2.5) <= string(3) "2.5"
|
||||
float(2.5) > NULL
|
||||
float(2.5) <= bool(true)
|
||||
float(2.5) > bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#1 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#2 (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
> object(test)#3 (0) {}
|
||||
float(2.5) <= array(0) {}
|
||||
float(2.5) > int(-2147483648)
|
||||
float(2.5) > string(11) "-2147483648"
|
||||
int(0) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) <= string(0) ""
|
||||
int(0) <= int(1)
|
||||
int(0) <= float(2.5)
|
||||
int(0) <= int(0)
|
||||
int(0) <= string(6) "string"
|
||||
int(0) <= string(3) "123"
|
||||
int(0) <= string(3) "2.5"
|
||||
int(0) <= NULL
|
||||
int(0) <= bool(true)
|
||||
int(0) <= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(0) <= array(0) {}
|
||||
int(0) > int(-2147483648)
|
||||
int(0) > string(11) "-2147483648"
|
||||
string(6) "string" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" > string(0) ""
|
||||
string(6) "string" <= int(1)
|
||||
string(6) "string" <= float(2.5)
|
||||
string(6) "string" <= int(0)
|
||||
string(6) "string" <= string(6) "string"
|
||||
string(6) "string" > string(3) "123"
|
||||
string(6) "string" > string(3) "2.5"
|
||||
string(6) "string" > NULL
|
||||
string(6) "string" <= bool(true)
|
||||
string(6) "string" > bool(false)
|
||||
string(6) "string" <= object(stdClass)#1 (0) {}
|
||||
string(6) "string" <= object(stdClass)#2 (0) {}
|
||||
string(6) "string" <= object(test)#3 (0) {}
|
||||
string(6) "string" <= array(0) {}
|
||||
string(6) "string" > int(-2147483648)
|
||||
string(6) "string" > string(11) "-2147483648"
|
||||
string(3) "123" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" > string(0) ""
|
||||
string(3) "123" > int(1)
|
||||
string(3) "123" > float(2.5)
|
||||
string(3) "123" > int(0)
|
||||
string(3) "123" <= string(6) "string"
|
||||
string(3) "123" <= string(3) "123"
|
||||
string(3) "123" > string(3) "2.5"
|
||||
string(3) "123" > NULL
|
||||
string(3) "123" <= bool(true)
|
||||
string(3) "123" > bool(false)
|
||||
string(3) "123" <= object(stdClass)#1 (0) {}
|
||||
string(3) "123" <= object(stdClass)#2 (0) {}
|
||||
string(3) "123" <= object(test)#3 (0) {}
|
||||
string(3) "123" <= array(0) {}
|
||||
string(3) "123" > int(-2147483648)
|
||||
string(3) "123" > string(11) "-2147483648"
|
||||
string(3) "2.5" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" > string(0) ""
|
||||
string(3) "2.5" > int(1)
|
||||
string(3) "2.5" <= float(2.5)
|
||||
string(3) "2.5" > int(0)
|
||||
string(3) "2.5" <= string(6) "string"
|
||||
string(3) "2.5" <= string(3) "123"
|
||||
string(3) "2.5" <= string(3) "2.5"
|
||||
string(3) "2.5" > NULL
|
||||
string(3) "2.5" <= bool(true)
|
||||
string(3) "2.5" > bool(false)
|
||||
string(3) "2.5" <= object(stdClass)#1 (0) {}
|
||||
string(3) "2.5" <= object(stdClass)#2 (0) {}
|
||||
string(3) "2.5" <= object(test)#3 (0) {}
|
||||
string(3) "2.5" <= array(0) {}
|
||||
string(3) "2.5" > int(-2147483648)
|
||||
string(3) "2.5" > string(11) "-2147483648"
|
||||
NULL <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL <= string(0) ""
|
||||
NULL <= int(1)
|
||||
NULL <= float(2.5)
|
||||
NULL <= int(0)
|
||||
NULL <= string(6) "string"
|
||||
NULL <= string(3) "123"
|
||||
NULL <= string(3) "2.5"
|
||||
NULL <= NULL
|
||||
NULL <= bool(true)
|
||||
NULL <= bool(false)
|
||||
NULL <= object(stdClass)#1 (0) {}
|
||||
NULL <= object(stdClass)#2 (0) {}
|
||||
NULL <= object(test)#3 (0) {}
|
||||
NULL <= array(0) {}
|
||||
NULL <= int(-2147483648)
|
||||
NULL <= string(11) "-2147483648"
|
||||
bool(true) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) > string(0) ""
|
||||
bool(true) <= int(1)
|
||||
bool(true) <= float(2.5)
|
||||
bool(true) > int(0)
|
||||
bool(true) <= string(6) "string"
|
||||
bool(true) <= string(3) "123"
|
||||
bool(true) <= string(3) "2.5"
|
||||
bool(true) > NULL
|
||||
bool(true) <= bool(true)
|
||||
bool(true) > bool(false)
|
||||
bool(true) <= object(stdClass)#1 (0) {}
|
||||
bool(true) <= object(stdClass)#2 (0) {}
|
||||
bool(true) <= object(test)#3 (0) {}
|
||||
bool(true) > array(0) {}
|
||||
bool(true) <= int(-2147483648)
|
||||
bool(true) <= string(11) "-2147483648"
|
||||
bool(false) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) <= string(0) ""
|
||||
bool(false) <= int(1)
|
||||
bool(false) <= float(2.5)
|
||||
bool(false) <= int(0)
|
||||
bool(false) <= string(6) "string"
|
||||
bool(false) <= string(3) "123"
|
||||
bool(false) <= string(3) "2.5"
|
||||
bool(false) <= NULL
|
||||
bool(false) <= bool(true)
|
||||
bool(false) <= bool(false)
|
||||
bool(false) <= object(stdClass)#1 (0) {}
|
||||
bool(false) <= object(stdClass)#2 (0) {}
|
||||
bool(false) <= object(test)#3 (0) {}
|
||||
bool(false) <= array(0) {}
|
||||
bool(false) <= int(-2147483648)
|
||||
bool(false) <= string(11) "-2147483648"
|
||||
object(stdClass)#1 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#1 (0) {} > string(0) ""
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#1 (0) {} > string(6) "string"
|
||||
object(stdClass)#1 (0) {} > string(3) "123"
|
||||
object(stdClass)#1 (0) {} > string(3) "2.5"
|
||||
object(stdClass)#1 (0) {} > NULL
|
||||
object(stdClass)#1 (0) {} <= bool(true)
|
||||
object(stdClass)#1 (0) {} > bool(false)
|
||||
object(stdClass)#1 (0) {} <= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#1 (0) {} <= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#1 (0) {} > object(test)#3 (0) {}
|
||||
object(stdClass)#1 (0) {} > array(0) {}
|
||||
object(stdClass)#1 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(stdClass)#1 (0) {} > string(11) "-2147483648"
|
||||
object(stdClass)#2 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#2 (0) {} > string(0) ""
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#2 (0) {} > string(6) "string"
|
||||
object(stdClass)#2 (0) {} > string(3) "123"
|
||||
object(stdClass)#2 (0) {} > string(3) "2.5"
|
||||
object(stdClass)#2 (0) {} > NULL
|
||||
object(stdClass)#2 (0) {} <= bool(true)
|
||||
object(stdClass)#2 (0) {} > bool(false)
|
||||
object(stdClass)#2 (0) {} <= object(stdClass)#1 (0) {}
|
||||
object(stdClass)#2 (0) {} <= object(stdClass)#2 (0) {}
|
||||
object(stdClass)#2 (0) {} > object(test)#3 (0) {}
|
||||
object(stdClass)#2 (0) {} > array(0) {}
|
||||
object(stdClass)#2 (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(stdClass)#2 (0) {} > string(11) "-2147483648"
|
||||
object(test)#3 (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#3 (0) {} > string(0) ""
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(test)#3 (0) {} > string(6) "string"
|
||||
object(test)#3 (0) {} > string(3) "123"
|
||||
object(test)#3 (0) {} > string(3) "2.5"
|
||||
object(test)#3 (0) {} > NULL
|
||||
object(test)#3 (0) {} <= bool(true)
|
||||
object(test)#3 (0) {} > bool(false)
|
||||
object(test)#3 (0) {} > object(stdClass)#1 (0) {}
|
||||
object(test)#3 (0) {} > object(stdClass)#2 (0) {}
|
||||
object(test)#3 (0) {} <= object(test)#3 (0) {}
|
||||
object(test)#3 (0) {} > array(0) {}
|
||||
object(test)#3 (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(-2147483648)
|
||||
object(test)#3 (0) {} > string(11) "-2147483648"
|
||||
array(0) {} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} > string(0) ""
|
||||
array(0) {} > int(1)
|
||||
array(0) {} > float(2.5)
|
||||
array(0) {} > int(0)
|
||||
array(0) {} > string(6) "string"
|
||||
array(0) {} > string(3) "123"
|
||||
array(0) {} > string(3) "2.5"
|
||||
array(0) {} <= NULL
|
||||
array(0) {} <= bool(true)
|
||||
array(0) {} <= bool(false)
|
||||
array(0) {} <= object(stdClass)#1 (0) {}
|
||||
array(0) {} <= object(stdClass)#2 (0) {}
|
||||
array(0) {} <= object(test)#3 (0) {}
|
||||
array(0) {} <= array(0) {}
|
||||
array(0) {} > int(-2147483648)
|
||||
array(0) {} > string(11) "-2147483648"
|
||||
int(-2147483648) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-2147483648) <= string(0) ""
|
||||
int(-2147483648) <= int(1)
|
||||
int(-2147483648) <= float(2.5)
|
||||
int(-2147483648) <= int(0)
|
||||
int(-2147483648) <= string(6) "string"
|
||||
int(-2147483648) <= string(3) "123"
|
||||
int(-2147483648) <= string(3) "2.5"
|
||||
int(-2147483648) > NULL
|
||||
int(-2147483648) <= bool(true)
|
||||
int(-2147483648) > bool(false)
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#1 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#2 (0) {}
|
||||
int(-2147483648)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#3 (0) {}
|
||||
int(-2147483648) <= array(0) {}
|
||||
int(-2147483648) <= int(-2147483648)
|
||||
int(-2147483648) <= string(11) "-2147483648"
|
||||
string(11) "-2147483648" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(11) "-2147483648" > string(0) ""
|
||||
string(11) "-2147483648" <= int(1)
|
||||
string(11) "-2147483648" <= float(2.5)
|
||||
string(11) "-2147483648" <= int(0)
|
||||
string(11) "-2147483648" <= string(6) "string"
|
||||
string(11) "-2147483648" <= string(3) "123"
|
||||
string(11) "-2147483648" <= string(3) "2.5"
|
||||
string(11) "-2147483648" > NULL
|
||||
string(11) "-2147483648" <= bool(true)
|
||||
string(11) "-2147483648" > bool(false)
|
||||
string(11) "-2147483648" <= object(stdClass)#1 (0) {}
|
||||
string(11) "-2147483648" <= object(stdClass)#2 (0) {}
|
||||
string(11) "-2147483648" <= object(test)#3 (0) {}
|
||||
string(11) "-2147483648" <= array(0) {}
|
||||
string(11) "-2147483648" <= int(-2147483648)
|
||||
string(11) "-2147483648" <= string(11) "-2147483648"
|
||||
Done
|
||||
@@ -0,0 +1,389 @@
|
||||
--TEST--
|
||||
comparing different variables (smaller or equal than)
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
}
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
new stdclass,
|
||||
new test,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
$var_cnt = count($a);
|
||||
|
||||
function my_dump($var) {
|
||||
ob_start();
|
||||
var_dump($var);
|
||||
$buf = ob_get_clean();
|
||||
echo str_replace("\n", "", $buf);
|
||||
}
|
||||
|
||||
foreach($a as $var) {
|
||||
for ($i = 0; $i < $var_cnt; $i++) {
|
||||
my_dump($var);
|
||||
echo ($var <= $a[$i]) ? " <= " : " > ";
|
||||
my_dump($a[$i]);
|
||||
echo "\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(0) ""
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(1)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > float(2.5)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(0)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(6) "string"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "123"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(3) "2.5"
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > NULL
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= bool(true)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > bool(false)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(stdClass)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} <= object(test)#%d (0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > array(0) {}
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > int(-9223372036854775808)
|
||||
array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)} > string(20) "-9223372036854775808"
|
||||
string(0) "" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(0) "" <= string(0) ""
|
||||
string(0) "" <= int(1)
|
||||
string(0) "" <= float(2.5)
|
||||
string(0) "" <= int(0)
|
||||
string(0) "" <= string(6) "string"
|
||||
string(0) "" <= string(3) "123"
|
||||
string(0) "" <= string(3) "2.5"
|
||||
string(0) "" <= NULL
|
||||
string(0) "" <= bool(true)
|
||||
string(0) "" <= bool(false)
|
||||
string(0) "" <= object(stdClass)#%d (0) {}
|
||||
string(0) "" <= object(stdClass)#%d (0) {}
|
||||
string(0) "" <= object(test)#%d (0) {}
|
||||
string(0) "" <= array(0) {}
|
||||
string(0) "" > int(-9223372036854775808)
|
||||
string(0) "" <= string(20) "-9223372036854775808"
|
||||
int(1) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(1) > string(0) ""
|
||||
int(1) <= int(1)
|
||||
int(1) <= float(2.5)
|
||||
int(1) > int(0)
|
||||
int(1) > string(6) "string"
|
||||
int(1) <= string(3) "123"
|
||||
int(1) <= string(3) "2.5"
|
||||
int(1) > NULL
|
||||
int(1) <= bool(true)
|
||||
int(1) > bool(false)
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(1)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(1) <= array(0) {}
|
||||
int(1) > int(-9223372036854775808)
|
||||
int(1) > string(20) "-9223372036854775808"
|
||||
float(2.5) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
float(2.5) > string(0) ""
|
||||
float(2.5) > int(1)
|
||||
float(2.5) <= float(2.5)
|
||||
float(2.5) > int(0)
|
||||
float(2.5) > string(6) "string"
|
||||
float(2.5) <= string(3) "123"
|
||||
float(2.5) <= string(3) "2.5"
|
||||
float(2.5) > NULL
|
||||
float(2.5) <= bool(true)
|
||||
float(2.5) > bool(false)
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
> object(stdClass)#%d (0) {}
|
||||
float(2.5)
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
> object(test)#%d (0) {}
|
||||
float(2.5) <= array(0) {}
|
||||
float(2.5) > int(-9223372036854775808)
|
||||
float(2.5) > string(20) "-9223372036854775808"
|
||||
int(0) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(0) <= string(0) ""
|
||||
int(0) <= int(1)
|
||||
int(0) <= float(2.5)
|
||||
int(0) <= int(0)
|
||||
int(0) <= string(6) "string"
|
||||
int(0) <= string(3) "123"
|
||||
int(0) <= string(3) "2.5"
|
||||
int(0) <= NULL
|
||||
int(0) <= bool(true)
|
||||
int(0) <= bool(false)
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(0)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(0) <= array(0) {}
|
||||
int(0) > int(-9223372036854775808)
|
||||
int(0) > string(20) "-9223372036854775808"
|
||||
string(6) "string" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(6) "string" > string(0) ""
|
||||
string(6) "string" <= int(1)
|
||||
string(6) "string" <= float(2.5)
|
||||
string(6) "string" <= int(0)
|
||||
string(6) "string" <= string(6) "string"
|
||||
string(6) "string" > string(3) "123"
|
||||
string(6) "string" > string(3) "2.5"
|
||||
string(6) "string" > NULL
|
||||
string(6) "string" <= bool(true)
|
||||
string(6) "string" > bool(false)
|
||||
string(6) "string" <= object(stdClass)#%d (0) {}
|
||||
string(6) "string" <= object(stdClass)#%d (0) {}
|
||||
string(6) "string" <= object(test)#%d (0) {}
|
||||
string(6) "string" <= array(0) {}
|
||||
string(6) "string" > int(-9223372036854775808)
|
||||
string(6) "string" > string(20) "-9223372036854775808"
|
||||
string(3) "123" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "123" > string(0) ""
|
||||
string(3) "123" > int(1)
|
||||
string(3) "123" > float(2.5)
|
||||
string(3) "123" > int(0)
|
||||
string(3) "123" <= string(6) "string"
|
||||
string(3) "123" <= string(3) "123"
|
||||
string(3) "123" > string(3) "2.5"
|
||||
string(3) "123" > NULL
|
||||
string(3) "123" <= bool(true)
|
||||
string(3) "123" > bool(false)
|
||||
string(3) "123" <= object(stdClass)#%d (0) {}
|
||||
string(3) "123" <= object(stdClass)#%d (0) {}
|
||||
string(3) "123" <= object(test)#%d (0) {}
|
||||
string(3) "123" <= array(0) {}
|
||||
string(3) "123" > int(-9223372036854775808)
|
||||
string(3) "123" > string(20) "-9223372036854775808"
|
||||
string(3) "2.5" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(3) "2.5" > string(0) ""
|
||||
string(3) "2.5" > int(1)
|
||||
string(3) "2.5" <= float(2.5)
|
||||
string(3) "2.5" > int(0)
|
||||
string(3) "2.5" <= string(6) "string"
|
||||
string(3) "2.5" <= string(3) "123"
|
||||
string(3) "2.5" <= string(3) "2.5"
|
||||
string(3) "2.5" > NULL
|
||||
string(3) "2.5" <= bool(true)
|
||||
string(3) "2.5" > bool(false)
|
||||
string(3) "2.5" <= object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" <= object(stdClass)#%d (0) {}
|
||||
string(3) "2.5" <= object(test)#%d (0) {}
|
||||
string(3) "2.5" <= array(0) {}
|
||||
string(3) "2.5" > int(-9223372036854775808)
|
||||
string(3) "2.5" > string(20) "-9223372036854775808"
|
||||
NULL <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
NULL <= string(0) ""
|
||||
NULL <= int(1)
|
||||
NULL <= float(2.5)
|
||||
NULL <= int(0)
|
||||
NULL <= string(6) "string"
|
||||
NULL <= string(3) "123"
|
||||
NULL <= string(3) "2.5"
|
||||
NULL <= NULL
|
||||
NULL <= bool(true)
|
||||
NULL <= bool(false)
|
||||
NULL <= object(stdClass)#%d (0) {}
|
||||
NULL <= object(stdClass)#%d (0) {}
|
||||
NULL <= object(test)#%d (0) {}
|
||||
NULL <= array(0) {}
|
||||
NULL <= int(-9223372036854775808)
|
||||
NULL <= string(20) "-9223372036854775808"
|
||||
bool(true) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(true) > string(0) ""
|
||||
bool(true) <= int(1)
|
||||
bool(true) <= float(2.5)
|
||||
bool(true) > int(0)
|
||||
bool(true) <= string(6) "string"
|
||||
bool(true) <= string(3) "123"
|
||||
bool(true) <= string(3) "2.5"
|
||||
bool(true) > NULL
|
||||
bool(true) <= bool(true)
|
||||
bool(true) > bool(false)
|
||||
bool(true) <= object(stdClass)#%d (0) {}
|
||||
bool(true) <= object(stdClass)#%d (0) {}
|
||||
bool(true) <= object(test)#%d (0) {}
|
||||
bool(true) > array(0) {}
|
||||
bool(true) <= int(-9223372036854775808)
|
||||
bool(true) <= string(20) "-9223372036854775808"
|
||||
bool(false) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
bool(false) <= string(0) ""
|
||||
bool(false) <= int(1)
|
||||
bool(false) <= float(2.5)
|
||||
bool(false) <= int(0)
|
||||
bool(false) <= string(6) "string"
|
||||
bool(false) <= string(3) "123"
|
||||
bool(false) <= string(3) "2.5"
|
||||
bool(false) <= NULL
|
||||
bool(false) <= bool(true)
|
||||
bool(false) <= bool(false)
|
||||
bool(false) <= object(stdClass)#%d (0) {}
|
||||
bool(false) <= object(stdClass)#%d (0) {}
|
||||
bool(false) <= object(test)#%d (0) {}
|
||||
bool(false) <= array(0) {}
|
||||
bool(false) <= int(-9223372036854775808)
|
||||
bool(false) <= string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} > string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#%d (0) {} > string(6) "string"
|
||||
object(stdClass)#%d (0) {} > string(3) "123"
|
||||
object(stdClass)#%d (0) {} > string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} > NULL
|
||||
object(stdClass)#%d (0) {} <= bool(true)
|
||||
object(stdClass)#%d (0) {} > bool(false)
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
object(stdClass)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(stdClass)#%d (0) {} > string(0) ""
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(stdClass)#%d (0) {} > string(6) "string"
|
||||
object(stdClass)#%d (0) {} > string(3) "123"
|
||||
object(stdClass)#%d (0) {} > string(3) "2.5"
|
||||
object(stdClass)#%d (0) {} > NULL
|
||||
object(stdClass)#%d (0) {} <= bool(true)
|
||||
object(stdClass)#%d (0) {} > bool(false)
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} <= object(stdClass)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > object(test)#%d (0) {}
|
||||
object(stdClass)#%d (0) {} > array(0) {}
|
||||
object(stdClass)#%d (0) {}
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(stdClass)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
object(test)#%d (0) {} > array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
object(test)#%d (0) {} > string(0) ""
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= int(1)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to double in %s on line %d
|
||||
<= float(2.5)
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(0)
|
||||
object(test)#%d (0) {} > string(6) "string"
|
||||
object(test)#%d (0) {} > string(3) "123"
|
||||
object(test)#%d (0) {} > string(3) "2.5"
|
||||
object(test)#%d (0) {} > NULL
|
||||
object(test)#%d (0) {} <= bool(true)
|
||||
object(test)#%d (0) {} > bool(false)
|
||||
object(test)#%d (0) {} > object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} > object(stdClass)#%d (0) {}
|
||||
object(test)#%d (0) {} <= object(test)#%d (0) {}
|
||||
object(test)#%d (0) {} > array(0) {}
|
||||
object(test)#%d (0) {}
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
> int(-9223372036854775808)
|
||||
object(test)#%d (0) {} > string(20) "-9223372036854775808"
|
||||
array(0) {} <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
array(0) {} > string(0) ""
|
||||
array(0) {} > int(1)
|
||||
array(0) {} > float(2.5)
|
||||
array(0) {} > int(0)
|
||||
array(0) {} > string(6) "string"
|
||||
array(0) {} > string(3) "123"
|
||||
array(0) {} > string(3) "2.5"
|
||||
array(0) {} <= NULL
|
||||
array(0) {} <= bool(true)
|
||||
array(0) {} <= bool(false)
|
||||
array(0) {} <= object(stdClass)#%d (0) {}
|
||||
array(0) {} <= object(stdClass)#%d (0) {}
|
||||
array(0) {} <= object(test)#%d (0) {}
|
||||
array(0) {} <= array(0) {}
|
||||
array(0) {} > int(-9223372036854775808)
|
||||
array(0) {} > string(20) "-9223372036854775808"
|
||||
int(-9223372036854775808) <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
int(-9223372036854775808) <= string(0) ""
|
||||
int(-9223372036854775808) <= int(1)
|
||||
int(-9223372036854775808) <= float(2.5)
|
||||
int(-9223372036854775808) <= int(0)
|
||||
int(-9223372036854775808) <= string(6) "string"
|
||||
int(-9223372036854775808) <= string(3) "123"
|
||||
int(-9223372036854775808) <= string(3) "2.5"
|
||||
int(-9223372036854775808) > NULL
|
||||
int(-9223372036854775808) <= bool(true)
|
||||
int(-9223372036854775808) > bool(false)
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class stdClass could not be converted to int in %s on line %d
|
||||
<= object(stdClass)#%d (0) {}
|
||||
int(-9223372036854775808)
|
||||
Notice: Object of class test could not be converted to int in %s on line %d
|
||||
<= object(test)#%d (0) {}
|
||||
int(-9223372036854775808) <= array(0) {}
|
||||
int(-9223372036854775808) <= int(-9223372036854775808)
|
||||
int(-9223372036854775808) <= string(20) "-9223372036854775808"
|
||||
string(20) "-9223372036854775808" <= array(3) { [0]=> int(1) [1]=> int(2) [2]=> int(3)}
|
||||
string(20) "-9223372036854775808" > string(0) ""
|
||||
string(20) "-9223372036854775808" <= int(1)
|
||||
string(20) "-9223372036854775808" <= float(2.5)
|
||||
string(20) "-9223372036854775808" <= int(0)
|
||||
string(20) "-9223372036854775808" <= string(6) "string"
|
||||
string(20) "-9223372036854775808" <= string(3) "123"
|
||||
string(20) "-9223372036854775808" <= string(3) "2.5"
|
||||
string(20) "-9223372036854775808" > NULL
|
||||
string(20) "-9223372036854775808" <= bool(true)
|
||||
string(20) "-9223372036854775808" > bool(false)
|
||||
string(20) "-9223372036854775808" <= object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= object(stdClass)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= object(test)#%d (0) {}
|
||||
string(20) "-9223372036854775808" <= array(0) {}
|
||||
string(20) "-9223372036854775808" <= int(-9223372036854775808)
|
||||
string(20) "-9223372036854775808" <= string(20) "-9223372036854775808"
|
||||
Done
|
||||
@@ -0,0 +1,78 @@
|
||||
--TEST--
|
||||
concat difffent types
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
class test {
|
||||
function __toString() {
|
||||
return "this is test object";
|
||||
}
|
||||
}
|
||||
|
||||
$a = array(1,2,3);
|
||||
$o = new test;
|
||||
$s = "some string";
|
||||
$i = 222;
|
||||
$d = 2323.444;
|
||||
|
||||
var_dump($a.$o);
|
||||
var_dump($a.$s);
|
||||
var_dump($a.$i);
|
||||
var_dump($a.$d);
|
||||
var_dump($a.$a);
|
||||
|
||||
var_dump($o.$a);
|
||||
var_dump($o.$s);
|
||||
var_dump($o.$i);
|
||||
var_dump($o.$d);
|
||||
var_dump($o.$o);
|
||||
|
||||
var_dump($s.$o);
|
||||
var_dump($s.$a);
|
||||
var_dump($s.$i);
|
||||
var_dump($s.$d);
|
||||
var_dump($s.$s);
|
||||
|
||||
var_dump($i.$a);
|
||||
var_dump($i.$o);
|
||||
var_dump($i.$s);
|
||||
var_dump($i.$d);
|
||||
var_dump($i.$i);
|
||||
|
||||
var_dump($d.$a);
|
||||
var_dump($d.$o);
|
||||
var_dump($d.$s);
|
||||
var_dump($d.$i);
|
||||
var_dump($d.$d);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
string(24) "Arraythis is test object"
|
||||
string(16) "Arraysome string"
|
||||
string(8) "Array222"
|
||||
string(13) "Array2323.444"
|
||||
string(10) "ArrayArray"
|
||||
string(24) "this is test objectArray"
|
||||
string(30) "this is test objectsome string"
|
||||
string(22) "this is test object222"
|
||||
string(27) "this is test object2323.444"
|
||||
string(38) "this is test objectthis is test object"
|
||||
string(30) "some stringthis is test object"
|
||||
string(16) "some stringArray"
|
||||
string(14) "some string222"
|
||||
string(19) "some string2323.444"
|
||||
string(22) "some stringsome string"
|
||||
string(8) "222Array"
|
||||
string(22) "222this is test object"
|
||||
string(14) "222some string"
|
||||
string(11) "2222323.444"
|
||||
string(6) "222222"
|
||||
string(13) "2323.444Array"
|
||||
string(27) "2323.444this is test object"
|
||||
string(19) "2323.444some string"
|
||||
string(11) "2323.444222"
|
||||
string(16) "2323.4442323.444"
|
||||
Done
|
||||
@@ -0,0 +1,60 @@
|
||||
--TEST--
|
||||
decrementing different variables
|
||||
--SKIPIF--
|
||||
<?php if (PHP_INT_SIZE != 4) die("skip this test is for 32bit platform only"); ?>
|
||||
--INI--
|
||||
precision=14
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
$a = array(
|
||||
array(1,2,3),
|
||||
"",
|
||||
1,
|
||||
2.5,
|
||||
0,
|
||||
"string",
|
||||
"123",
|
||||
"2.5",
|
||||
NULL,
|
||||
true,
|
||||
false,
|
||||
new stdclass,
|
||||
array(),
|
||||
-PHP_INT_MAX-1,
|
||||
(string)(-PHP_INT_MAX-1),
|
||||
);
|
||||
|
||||
foreach ($a as $var) {
|
||||
$var--;
|
||||
var_dump($var);
|
||||
}
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(3) {
|
||||
[0]=>
|
||||
int(1)
|
||||
[1]=>
|
||||
int(2)
|
||||
[2]=>
|
||||
int(3)
|
||||
}
|
||||
int(-1)
|
||||
int(0)
|
||||
float(1.5)
|
||||
int(-1)
|
||||
string(6) "string"
|
||||
int(122)
|
||||
float(1.5)
|
||||
NULL
|
||||
bool(true)
|
||||
bool(false)
|
||||
object(stdClass)#%d (0) {
|
||||
}
|
||||
array(0) {
|
||||
}
|
||||
float(-2147483649)
|
||||
float(-2147483649)
|
||||
Done
|
||||
Loaded 100 of 2375 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user