member variable and member function have the same name
See the chapter on Class Basic in the PHP manual:
$ins->isNew // class member
$ins->isNew() // class method
$ins->isNew
is the variable.
$ins->isNew()
is the function.
PHP is not a functional programming language where functions are also data. So $ins->isNew
wouldn’t be ambiguous to either refer to the method isNew
or the attribute isNew
. $ins->isNew
is always an attribute and $ins->isNew()
a method call.