Since 4.0 and the move to PHP5, a lot of named constants were transformed as class constants.
For instance 'EZ_ERROR_KERNEL_ACCESS_DENIED' became 'eZError::KERNEL_ACCESS_DENIED'.
Some of those named constants were kept/moved to "reference files", for instance, since 4.0, the file kernel/error/errors.php contains all the old EZ_ERROR_* name constants with a warning about the fact that these constants are deprecated.
Problem : there is still some legit eZ Publish kernel code using those constants.
For instance in 4.0.7, 4.1.4, 4.2.0 and 4.3.0 :
- kernel/collaboration/item.php uses EZ_ERROR_KERNEL_NOT_AVAILABLE
- kernel/content/restore.php uses EZ_ERROR_KERNEL_NOT_AVAILABLE
- kernel/package/upload.php uses EZ_ERROR_KERNEL_ACCESS_DENIED
- kernel/shop/confirmorder.php uses EZ_ERROR_KERNEL_NOT_AVAILABLE
In 4.0.7, the only reference to the kernel/error/errors.php file are commented include/include_once or require/require_once.
In later releases, there seems to be no reference to the kernel/error/errors.php file.
So, IMHO, there is no way the lines of code using those deprecated named constants would behave exactly as expected...