symfony / polyfill-php70
Symfony polyfill 将一些 PHP 7.0+ 特性回退到较低版本的 PHP
v1.20.0
2020-10-23 14:02 UTC
Requires
- php: >=7.1
README
此组件提供了在 PHP 7.0 之前版本中不可用的功能
intdivpreg_replace_callback_arrayerror_clear_lastrandom_bytes和random_int(来自 paragonie/random_compat)*Error可抛出类PHP_INT_MINSessionUpdateTimestampHandlerInterface
更多信息可以在 主 Polyfill README 中找到。
兼容性说明
要编写在 PHP5 和 PHP7 之间可移植的代码,需要注意一些事项
\*Error异常必须在\Exception之前被捕获;- 在调用
error_clear_last()之后,必须使用isset($e['message'][0])而不是null !== $e来验证$e = error_get_last()的结果。
许可证
此库在 MIT 许可证 下发布。