PHP 5.6.0. Released
PHP 5.6.0. Released
Written by Ian Elliot   
Friday, 29 August 2014

PHP 5.6 brings with it  new and improved features including an interactive debugger, and has some backward incompatible changes. 

The headline new feature in PHP 5.6 is constant scalar expressions.

This means it is now possible to provide a scalar expression involving numeric and string literals and/or constants in contexts where PHP previously expected a static value, such as constant and property declarations and default function arguments as demonstrated with this example:

 php56eg

 

Which produces this output:

 

 

Other new features are:

  • Variadic functions and argument unpacking using the ... operator 
  • Exponentiation using the ** operator
  • Function and constant importing with the use keyword.
  • php://input is now reusable, and $HTTP_RAW_POST_DATA is deprecated
  • GMP (arbitrary length integer) objects now support operator overloading
  • File uploads larger than 2 gigabytes in size are now accepted

The following changes affect compatibility: 

  • Array keys won't be overwritten when defining an array as a property of a class via an array literal
  • json_decode() is more strict in JSON syntax parsing
  • Stream wrappers now verify peer certificates and host names by default when using SSL/TLS
  • GMP resources are now objects
  • Mcrypt functions now require valid keys and IVs

All these changes are documented in a migration guide and other improvements and bug fixes are listed in the Change Log.

There is also a Getting Started guide for phpdbg, the new interactive debugger which is implemented and distributed as a SAPI module, just as the CLI interface. It integrates with an initializes the Zend environment. 

 

phplogo

 

Banner


The Truck Factor Revealed
16/07/2015

Don't take this too seriously, but if 90 programmers working on the Linux kernel were to be hit by a truck then the project, and hence Linux, would be toast. If a truck score of 90 seems good what abo [ ... ]



Wear Your Favourite Cellular Automaton As A Scarf
19/07/2015

KnitYak is a KickStarter with the aim of bringing you your very own custom cellular automata scarf. You select the 1D automaton and the machine knits it for you. 


More News

 

blog comments powered by Disqus

 

 

Last Updated ( Friday, 29 August 2014 )
 
 

   
RSS feed of news items only
I Programmer News
Copyright © 2015 i-programmer.info. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.