--TEST-- ReflectionClass::getConstants() --FILE-- getConstant('a')); var_dump($rc->getConstant('doesntexist')); } ?> --EXPECT-- Reflecting on class C: string(12) "hello from C" bool(false) Reflecting on class D: string(12) "hello from C" bool(false) Reflecting on class E: string(12) "hello from C" bool(false) Reflecting on class F: string(12) "hello from F" bool(false) Reflecting on class X: bool(false) bool(false)