"Object with no values or functions"
Posted: Tue Oct 24, 2006 9:48 pm
I was just casually browsing the 2nd edition of "Programming PHP" from O'Reilly and in the section regarding what evaluates to false it states "An object with no values or functions". But when I test this with:
The assertion fails.
Is this an error in the book?
Code: Select all
class EmptyClass {}
assert(new EmptyClass() == false);Is this an error in the book?