PHP 各版本特性
来源:互联网 发布:万网域名注册网站 编辑:程序博客网 时间:2024/06/04 18:02
链接
PHP5.3
PHP5.4
PHP5.5
PHP5.6
PHP7.0
PHP7.1
PHP7.2
PHP 5.3.0 offers a wide range of new features:
- Support for namespaces has been added.
- Support for Late Static Bindings has been added.
- Support for jump labels (limited goto) has been added.
- Support for native Closures (Lambda/Anonymous functions) has been added.
- There are two new magic methods, __callStatic() and __invoke().
Nowdoc syntax is now supported, similar to Heredoc syntax, but with single quotes. - It is now possible to use Heredocs to initialize static variables and class properties/constants.
- Heredocs may now be declared using double quotes, complementing the Nowdoc syntax.
- Constants can now be declared outside a class using the const keyword.
- The ternary operator now has a shorthand form: ?:.
- The HTTP stream wrapper now considers all status codes from 200 to 399 to be successful.
- Dynamic access to static methods is now possible:
PHP 5.4.0 offers a wide range of new features:
- Support for traits has been added.
- Short array syntax has been added, e.g.
a=[1,2,3,4];or a = [‘one’ => 1, ‘two’ => 2, ‘three’ => 3, ‘four’ => 4];. - Function array dereferencing has been added, e.g. foo()[0].
- Closures now support $this.
PHP 5.5.0 offers a wide range of new features:
- Generators added
- finally keyword added
- New password hashing API
- foreach now supports list()
- empty() supports arbitrary expressions
- array and string literal dereferencing
- Class name resolution via ::class
- OPcache extension added
- foreach now supports non-scalar keys
- Apache 2.4 handler supported on Windows
- Improvements to GD
PHP 5.6.0 offers a wide range of new features:
- Constant expressions
- Variadic functions via …
- Argument unpacking via …
- Exponentiation via **
- use function and use const
- phpdbg
- Default character encoding
- Large file uploads
- GMP supports operator overloading
- hash_equals() for timing attack safe string comparison
- __debugInfo()
- gost-crypto hash algorithm
- SSL/TLS improvements
- pgsql async support
PHP 7.0.0 offers a wide range of new features:
- Scalar type declarations
- Return type declarations
- Null coalescing operator
- Spaceship operator
- Constant arrays using define()
- Anonymous classes
- Unicode codepoint escape syntax
- Closure::call()
- Filtered unserialize()
- IntlChar
- Expectations
- Group use declarations
- Generator delegation
- Integer division with intdiv()
- Session options
- preg_replace_callback_array()
- CSPRNG Functions
- list() can always unpack objects implementing ArrayAccess
- Class member access on cloning has been added, e.g. (clone $foo)->bar().
PHP 7.1.0 offers a wide range of new features:
- Nullable types
- Void functions
- Symmetric array destructuring
- Class constant visibility
- iterable pseudo-type
- Multi catch exception handling
- Support for keys in list()
- Support for negative string offsets
- Support for AEAD in ext/openssl
- Convert callables to Closures with Closure::fromCallable()
- Asynchronous signal handling
HTTP/2 server push support in ext/curl
PHP 7.2.0 offers a wide range of new features:
- New object type
- Extension loading by name
- Abstract method overriding
- Sodium is now a core extension
- Password hashing with Argon2
- Extended string types for PDO
- Additional emulated prepares debugging information for PDO
- Support for extended operations in LDAP
- Address Information additions to the Sockets extension
- Parameter type widening
- Allow a trailing comma for grouped namespaces
- proc_nice() support on Windows
- pack() and unpack() endian support
- Enhancements to the EXIF extension
- New features in PCRE
- SQLite3 allows writing BLOBs
- Oracle OCI8 Transparent Application Failover Callbacks
- Enhancements to the ZIP extension
阅读全文
0 0
- PHP 各版本特性
- PHP版本特性笔记
- php各个版本特性
- PHP不同版本之特性
- PHP语言特性和各版本的差异
- PHP语言特性和各版本的差异
- ios各版本特性
- JDK各版本特性
- iOS各版本特性
- android各版本特性
- android各版本特性
- PHP版本-对应的新特性
- PHP版本-对应的新特性
- PHP各个版本的新特性
- Impala各版本新特性
- Impala各版本新特性
- Impala各版本新特性
- JAVA各版本更新特性
- eNSP三层交换机配置-02
- 取消Tomcat post长度限制的方法
- chrome插件 xpath-helper的安装
- iOS离线打包项目升级5+SDK
- node.js异步式IO与事件式编程
- PHP 各版本特性
- MSP430 ADC12采样分析
- docker默认存放以及docker 非root用户
- tensorflow训练神经网络-提取MFCC特征
- Spring mvc数据模型,视图 和 视图解析器
- Cocos2d-x下Lua调用自定义C++类和函数的最佳实践
- VMWARE虚拟机开机失败的一些现象与解决汇总
- 我的javascript权威指南-10
- spring cloud系列-03.程序启动时做额外操作