blob: 0fd56f0ceda58fea35150f21c243050e783873b4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
--TEST--
Bug #78810: RW fetches do not throw "uninitialized property" exception
--FILE--
<?php
class Test {
public int $i;
}
$test = new Test;
try {
$test->i++;
} catch (Error $e) {
echo $e->getMessage(), "\n";
}
try {
$test->i += 1;
} catch (Error $e) {
echo $e->getMessage(), "\n";
}
?>
--EXPECT--
Typed property Test::$i must not be accessed before initialization
Typed property Test::$i must not be accessed before initialization
|