mirror of
https://github.com/phpv8/v8js.git
synced 2024-12-22 15:11:53 +00:00
Rename constructor functions to __construct
This commit is contained in:
parent
4002c3c1ae
commit
cbbce91ffd
@ -6,7 +6,7 @@ Test V8::executeString() : Get constructor method
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
class Foo {
|
class Foo {
|
||||||
function Foo() {
|
function __construct() {
|
||||||
echo "called constructor: ";
|
echo "called constructor: ";
|
||||||
var_dump(func_get_args());
|
var_dump(func_get_args());
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ class Foo {
|
|||||||
var $bar = 'foobar';
|
var $bar = 'foobar';
|
||||||
var $nullprop = null;
|
var $nullprop = null;
|
||||||
|
|
||||||
function Foo() {
|
function __construct() {
|
||||||
echo "called constructor: ";
|
echo "called constructor: ";
|
||||||
var_dump(func_get_args());
|
var_dump(func_get_args());
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user