forked from php/php-src
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- php-8.2.1
- php-8.2.1RC1
- php-8.2.0
- php-8.2.0beta3
- php-8.2.0beta2
- php-8.2.0beta1
- php-8.2.0alpha3
- php-8.2.0alpha2
- php-8.2.0alpha1
- php-8.2.0RC7
- php-8.2.0RC6
- php-8.2.0RC5
- php-8.2.0RC4
- php-8.2.0RC3
- php-8.2.0RC2
- php-8.2.0RC1
- php-8.1.14
- php-8.1.14RC1
- php-8.1.13
- php-8.1.13RC1
- php-8.1.12
- php-8.1.12RC1
- php-8.1.11
- php-8.1.11RC1
- php-8.1.10
- php-8.1.10RC1
- php-8.1.9
- php-8.1.9RC1
- php-8.1.8
- php-8.1.8RC1
- php-8.1.7
- php-8.1.7RC1
- php-8.1.6
- php-8.1.6RC1
- php-8.1.5
- php-8.1.5RC1
- php-8.1.4
- php-8.1.4RC1
- php-8.1.3
- php-8.1.3RC1
- php-8.1.2
- php-8.1.2RC1
- php-8.1.1
- php-8.1.1RC1
- php-8.1.0
- php-8.1.0beta3
- php-8.1.0beta2
- php-8.1.0beta1
- php-8.1.0alpha3
- php-8.1.0alpha2
- php-8.1.0alpha1
- php-8.1.0RC6
- php-8.1.0RC5
- php-8.1.0RC4
- php-8.1.0RC3
- php-8.1.0RC2
- php-8.1.0RC1
- php-8.0.27
- php-8.0.26
- php-8.0.26RC1
- php-8.0.25
- php-8.0.25RC1
- php-8.0.24
- php-8.0.24RC1
- php-8.0.23
- php-8.0.23RC1
- php-8.0.22
- php-8.0.22RC1
- php-8.0.21
- php-8.0.21RC1
- php-8.0.20
- php-8.0.20RC1
- php-8.0.19
- php-8.0.19RC1
- php-8.0.18
- php-8.0.18RC1
- php-8.0.17
- php-8.0.17RC1
- php-8.0.16
- php-8.0.16RC1
- php-8.0.15
- php-8.0.15RC1
- php-8.0.14
- php-8.0.14RC1
- php-8.0.13
- php-8.0.13RC1
- php-8.0.12
- php-8.0.12RC1
- php-8.0.11
- php-8.0.11RC1
- php-8.0.10
- php-8.0.10RC1
- php-8.0.9
- php-8.0.9RC1
- php-8.0.8
- php-8.0.8RC1
- php-8.0.7
- php-8.0.7RC1
- php-8.0.6
- php-8.0.5
- php-8.0.5RC1
- php-8.0.4RC1
- php-8.0.3
- php-8.0.3RC1
- php-8.0.2
- php-8.0.2RC1
- php-8.0.1
- php-8.0.1RC1
- php-8.0.0
- php-8.0.0rc1
- php-8.0.0beta4
- php-8.0.0beta3
- php-8.0.0beta2
- php-8.0.0beta1
- php-8.0.0alpha3
- php-8.0.0alpha2
- php-8.0.0alpha1
- php-8.0.0RC5
- php-8.0.0RC4
- php-8.0.0RC3
- php-8.0.0RC2
- php-7.4.33
- php-7.4.32
- php-7.4.31
- php-7.4.30
- php-7.4.29
- php-7.4.28
- php-7.4.27
- php-7.4.27RC1
- php-7.4.26
- php-7.4.26RC1
- php-7.4.25
- php-7.4.25RC1
- php-7.4.24
- php-7.4.24RC1
- php-7.4.23
- php-7.4.23RC1
- php-7.4.22
- php-7.4.22RC1
- php-7.4.21
- php-7.4.21RC1
- php-7.4.20
- php-7.4.20RC1
- php-7.4.19
- php-7.4.18
- php-7.4.18RC1
- php-7.4.17RC1
- php-7.4.16
- php-7.4.16RC1
- php-7.4.15
- php-7.4.15RC2
- php-7.4.15RC1
- php-7.4.14
- php-7.4.14RC1
- php-7.4.13
- php-7.4.13RC1
- php-7.4.12
- php-7.4.12RC1
- php-7.4.11
- php-7.4.11RC1
- php-7.4.10
- php-7.4.10RC1
- php-7.4.9
- php-7.4.9RC1
- php-7.4.8
- php-7.4.8RC1
- php-7.4.7
- php-7.4.7RC1
- php-7.4.6
- php-7.4.6RC1
- php-7.4.5
- php-7.4.5RC1
- php-7.4.4
- php-7.4.4RC1
- php-7.4.3
- php-7.4.3RC1
- php-7.4.2
- php-7.4.2RC1
- php-7.4.1
- php-7.4.1RC1
- php-7.4.0
- php-7.4.0beta4
- php-7.4.0beta2
- php-7.4.0beta1
- php-7.4.0alpha3
- php-7.4.0alpha2
- php-7.4.0alpha1
- php-7.4.0RC6
- php-7.4.0RC5
- php-7.4.0RC4
- php-7.4.0RC3
- php-7.4.0RC2
- php-7.4.0RC1
- php-7.3.33
- php-7.3.32
- php-7.3.31
- php-7.3.30
- php-7.3.29
- php-7.3.28
- php-7.3.27
- php-7.3.26
- php-7.3.26RC1
- php-7.3.25
- php-7.3.25RC1
- php-7.3.24
- php-7.3.24RC1
- php-7.3.23
- php-7.3.23RC1
- php-7.3.22
- php-7.3.22RC1
- php-7.3.21
- php-7.3.21RC1
- php-7.3.20
- php-7.3.20RC1
- php-7.3.19
- php-7.3.19RC1
- php-7.3.18
- php-7.3.18RC1
- php-7.3.17
- php-7.3.17RC1
- php-7.3.16
- php-7.3.16RC1
- php-7.3.15
- php-7.3.15RC1
- php-7.3.14
- php-7.3.14RC1
- php-7.3.13
- php-7.3.13RC1
- php-7.3.12
- php-7.3.12RC1
- php-7.3.11
- php-7.3.11RC1
- php-7.3.10
- php-7.3.10RC1
- php-7.3.9
- php-7.3.9RC1
- php-7.3.8
- php-7.3.8RC1
- php-7.3.7
- php-7.3.7RC3
- php-7.3.7RC2
- php-7.3.7RC1
- php-7.3.6
- php-7.3.6RC1
- php-7.3.5
- php-7.3.5RC1
- php-7.3.4
- php-7.3.4RC1
- php-7.3.3
- php-7.3.3RC1
- php-7.3.2
- php-7.3.2RC1
- php-7.3.1
- php-7.3.1RC1
- php-7.3.0
- php-7.3.0beta3
- php-7.3.0beta2
- php-7.3.0beta1
- php-7.3.0alpha4
- php-7.3.0alpha3
- php-7.3.0alpha2
- php-7.3.0alpha1
- php-7.3.0RC6
- php-7.3.0RC5
- php-7.3.0RC4
- php-7.3.0RC3
- php-7.3.0RC2
- php-7.3.0RC1
- php-7.2.34
- php-7.2.33
- php-7.2.32
- php-7.2.31
- php-7.2.30
- php-7.2.29
- php-7.2.28
- php-7.2.27
- php-7.2.26
- php-7.2.26RC1
- php-7.2.25
- php-7.2.25RC1
- php-7.2.24
- php-7.2.24RC1
- php-7.2.23
- php-7.2.23RC1
- php-7.2.22
- php-7.2.22RC1
- php-7.2.21
- php-7.2.21RC1
- php-7.2.20
- php-7.2.20RC2
- php-7.2.20RC1
- php-7.2.19
- php-7.2.19RC1
- php-7.2.18
- php-7.2.18RC1
- php-7.2.17
- php-7.2.17RC1
- php-7.2.16
- php-7.2.16RC1
- php-7.2.15
- php-7.2.15RC1
- php-7.2.14
- php-7.2.14RC1
- php-7.2.13
- php-7.2.13RC1
- php-7.2.12
- php-7.2.12RC1
- php-7.2.11
- php-7.2.11RC1
- php-7.2.10
- php-7.2.10RC1
- php-7.2.9
- php-7.2.9RC1
- php-7.2.8
- php-7.2.8RC1
- php-7.2.7
- php-7.2.7RC1
- php-7.2.6
- php-7.2.6RC1
- php-7.2.5
- php-7.2.5RC1
- php-7.2.4
- php-7.2.4RC1
- php-7.2.3
- php-7.2.3RC1
- php-7.2.2
- php-7.2.2RC1
- php-7.2.1
- php-7.2.1RC1
- php-7.2.0
- php-7.2.0beta3
- php-7.2.0beta2
- php-7.2.0beta1
- php-7.2.0alpha3
- php-7.2.0alpha2
- php-7.2.0alpha1
- php-7.2.0RC6
- php-7.2.0RC5
- php-7.2.0RC4
- php-7.2.0RC3
- php-7.2.0RC2
- php-7.2.0RC1
- php-7.1.33
- php-7.1.32
- php-7.1.31
- php-7.1.30
- php-7.1.29
- php-7.1.28
- php-7.1.27
- php-7.1.26
- php-7.1.25
- php-7.1.25RC1
- php-7.1.24
- php-7.1.24RC1
- php-7.1.23
- php-7.1.23RC1
- php-7.1.22
- php-7.1.22RC1
- php-7.1.21
- php-7.1.21RC1
- php-7.1.20
- php-7.1.20RC1
- php-7.1.19
- php-7.1.19RC1
- php-7.1.18
- php-7.1.18RC1
- php-7.1.17
- php-7.1.17RC1
- php-7.1.16
- php-7.1.16RC1
- php-7.1.15
- php-7.1.15RC1
- php-7.1.14
- php-7.1.14RC1
- php-7.1.13
- php-7.1.13RC1
- php-7.1.12
- php-7.1.12RC1
- php-7.1.11
- php-7.1.11RC1
- php-7.1.10
- php-7.1.10RC1
- php-7.1.9
- php-7.1.9RC1
- php-7.1.8
- php-7.1.8RC1
- php-7.1.7
- php-7.1.7RC1
- php-7.0.33
- php-7.0.32
- php-7.0.31
- php-7.0.30
- php-7.0.29
- php-7.0.28
- php-7.0.27
- php-7.0.27RC1
- php-7.0.26
- php-7.0.26RC1
- php-7.0.25
- php-7.0.25RC1
- php-7.0.24
- php-7.0.24RC1
- php-7.0.23
- php-7.0.23RC1
- php-7.0.22
- php-7.0.22RC1
- php-7.0.21
- php-7.0.21RC1
- l
Showing
3 changed files
with
80 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
--TEST-- | ||
Bug #74478: null coalescing operator failing with SplFixedArray | ||
--FILE-- | ||
<?php | ||
|
||
class MyFixedArray extends \SplFixedArray | ||
{ | ||
public function offsetExists($name) { | ||
echo "offsetExists($name)\n"; | ||
return parent::offsetExists($name); | ||
} | ||
public function offsetGet($name) { | ||
echo "offsetGet($name)\n"; | ||
return parent::offsetGet($name); | ||
} | ||
public function offsetSet($name, $value) { | ||
echo "offsetSet($name)\n"; | ||
return parent::offsetSet($name, $value); | ||
} | ||
public function offsetUnset($name) { | ||
echo "offsetUnset($name)\n"; | ||
return parent::offsetUnset($name); | ||
} | ||
|
||
}; | ||
|
||
$fixedData = new MyFixedArray(10); | ||
var_dump(isset($fixedData[0][1][2])); | ||
var_dump(isset($fixedData[0]->foo)); | ||
var_dump($fixedData[0] ?? 42); | ||
var_dump($fixedData[0][1][2] ?? 42); | ||
|
||
$fixedData[0] = new MyFixedArray(10); | ||
$fixedData[0][1] = new MyFixedArray(10); | ||
var_dump(isset($fixedData[0][1][2])); | ||
var_dump($fixedData[0][1][2] ?? 42); | ||
|
||
?> | ||
--EXPECT-- | ||
offsetExists(0) | ||
bool(false) | ||
offsetExists(0) | ||
bool(false) | ||
offsetExists(0) | ||
int(42) | ||
offsetExists(0) | ||
int(42) | ||
offsetSet(0) | ||
offsetGet(0) | ||
offsetSet(1) | ||
offsetExists(0) | ||
offsetGet(0) | ||
offsetExists(1) | ||
offsetGet(1) | ||
offsetExists(2) | ||
bool(false) | ||
offsetExists(0) | ||
offsetGet(0) | ||
offsetExists(1) | ||
offsetGet(1) | ||
offsetExists(2) | ||
int(42) |