xref: /PHP-8.0/ext/opcache/tests/opt/sccp_020.phpt (revision f8d79582)
1--TEST--
2SCCP 020: Object assignment
3--INI--
4opcache.enable=1
5opcache.enable_cli=1
6opcache.optimization_level=-1
7;opcache.opt_debug_level=0x20000
8--SKIPIF--
9<?php require_once('skipif.inc'); ?>
10--FILE--
11<?php
12function foo() {
13    $b = $a = new stdClass;
14    $a->x = 5;
15    $b->x = 42;
16    echo $a->x;
17    echo "\n";
18}
19foo();
20?>
21--EXPECT--
2242
23