You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Although the whole Scalar Type Hint implementation is up in the air, it's very likely that string will become a reserved word in PHP 7: https://wiki.php.net/rfc/scalar_type_hints#reserve_for_future_use
For this reason it might be worth looking into using a different name for this class:
Fatal error: "string" cannot be used as a class name in phar://C:/ProgramData/ComposerSetup/bin/composer.phar/vendor/justinrainbow/json-schema/src/JsonSchema/Constraints/String.php on line 18
@justinrainbow The RFC has been accepted. string, int, bool, float are now reserved. There is another rfc currently in voting to soft-reserve object (Not reserved immedeatly, but reserving it in 7.x will not be considered a BC break).
You might preserve BC by renaming the class and all its internal usages and conditionally alias (class_alias) it using it's old name on php < 7. And add a note that all projects depending on this class should use the new name if they want to be compatible with php7.
Although the whole Scalar Type Hint implementation is up in the air, it's very likely that string will become a reserved word in PHP 7: https://wiki.php.net/rfc/scalar_type_hints#reserve_for_future_use
For this reason it might be worth looking into using a different name for this class:
https://github.com/justinrainbow/json-schema/blob/master/src/JsonSchema/Constraints/String.php
Just a heads-up.
The text was updated successfully, but these errors were encountered: