. The default error_reporting level is now E_ALL. Previously it excluded
E_NOTICE and E_DEPRECATED.
. display_startup_errors is now enabled by default.
+ . Using "parent" inside a class that has no parent will now result in a
+ fatal compile-time error.
. The @ operator will no longer silence fatal errors (E_ERROR, E_CORE_ERROR,
E_COMPILE_ERROR, E_USER_ERROR, E_RECOVERABLE_ERROR, E_PARSE). Error handlers
that expect error_reporting to be 0 when @ is used, should be adjusted to
}
?>
--EXPECTF--
-Deprecated: Cannot use "parent" when current class scope has no parent in %s on line %d
-
-Fatal error: Uncaught Error: Cannot use "parent" when current class scope has no parent in %s:%d
-Stack trace:
-#0 {main}
- thrown in %s on line %d
+Fatal error: Cannot use "parent" when current class scope has no parent in %s on line %d
?>
--EXPECTF--
-Deprecated: Cannot use "parent" when current class scope has no parent in %s on line %d
-
-Fatal error: Could not check compatibility between B::method(A $x) and A::method(parent $x), because class parent is not available in %s on line %d
+Fatal error: Cannot use "parent" when current class scope has no parent in %s on line %d
fetch_type == ZEND_FETCH_CLASS_SELF ? "self" :
fetch_type == ZEND_FETCH_CLASS_PARENT ? "parent" : "static");
} else if (fetch_type == ZEND_FETCH_CLASS_PARENT && !ce->parent_name) {
- zend_error(E_DEPRECATED,
+ zend_error_noreturn(E_COMPILE_ERROR,
"Cannot use \"parent\" when current class scope has no parent");
}
}