mirror of
https://github.com/php/php-src.git
synced 2024-12-14 04:16:30 +08:00
20 lines
236 B
PHP
20 lines
236 B
PHP
--TEST--
|
|
Inc/dec of reference object properties
|
|
--FILE--
|
|
<?php
|
|
|
|
$obj = new stdClass;
|
|
$obj->cursor = 0;
|
|
$ref =& $obj->cursor;
|
|
|
|
$obj->cursor++;
|
|
var_dump($obj->cursor);
|
|
|
|
$obj->cursor--;
|
|
var_dump($obj->cursor);
|
|
|
|
?>
|
|
--EXPECT--
|
|
int(1)
|
|
int(0)
|