mirror of
https://github.com/php/php-src.git
synced 2024-12-25 01:40:50 +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)
|