--TEST-- new self / new parent in constant expression --FILE-- getMessage(), "\n"; } try { B::invalid(); } catch (Error $e) { echo $e->getMessage(), "\n"; } ?> --EXPECT-- object(B)#1 (0) { } object(A)#2 (0) { } Cannot access "self" when no class scope is active Cannot access "parent" when current class scope has no parent