Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- echo $non_existing_variable; // Error
- echo NON_EXISTING_CONSTANT; // Now also an error
- if (defined('CONSTANT')) {
- echo CONSTANT;
- } else {
- throw new Exception('Undefined Constant.');
- }
- class Config{
- const CONFIG_ONE = 42;
- }
- //will produce a fatal error
- if(Config::CONFIG_TWO){
- //...
- }
Add Comment
Please, Sign In to add comment