summaryrefslogtreecommitdiff
path: root/Zend/tests/varSyntax/new_instanceof_expr.phpt
blob: 475f7a9daecaf395f28e02414cce17f3906ac91a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--TEST--
new with an arbitrary expression
--FILE--
<?php

$class = 'class';
var_dump(new ('std'.$class));
var_dump(new ('std'.$class)());
$obj = new stdClass;
var_dump($obj instanceof ('std'.$class));

?>
--EXPECT--
object(stdClass)#1 (0) {
}
object(stdClass)#1 (0) {
}
bool(true)