New features in PHP 7

Soft Landing

© Lead Image © joingate, 123RF.com

© Lead Image © joingate, 123RF.com

Article from Issue 184/2016
Author(s):

How will developers have to change their PHP 5 scripts to conform to the new PHP 7? We look at some of the important changes.

PHP 7 [1] was just released at the end of 2015 and updated to version 7.0.2 early in January 2016. In addition to providing 64-bit support throughout, the new major release of the scripting language gets rid of a variety of ugly hacks. The "PHP 7 Install" box describes the installation of stable version 7.0.2.

Coming to Terms with the Past

The PHP 7 developers managed to increase the expressiveness of their linguistic resources by revising historical defects – at the expense of losing backward compatibility. However, it isn't necessarily the smaller changes that are responsible for the troubles. For example, PHP 7 might only still allow one default clause per switch instruction and prohibit the same function parameters as in:

function foo($value, $ignored, $ignored)

[...]

Use Express-Checkout link below to read the full article (PDF).

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Spider, Spider

    Scrapy is an open source framework written in Python that lets you build your own crawlers with minimal effort for professional results.

  • Rust Language

    We look at a few features of Rust, Mozilla's systems programming language, and its similarity to other languages.

  • Pony Programming Language

    Pony, an object-oriented programming language with static typecasting, trots down well-mapped paths to deliver secure, high-performance code for concurrent applications.

  • ECMAScript 6

    The new ECMAScript 6 language eliminates many historical problems associated with JavaScript.

  • Dotnet Scripting with Boo

    Boo is a scripting language tailor-made for Mono and .NET. This haunting mixture of Python and C# may be just what you need to get started with the .NET framework.

comments powered by Disqus