Get your next remote job on LaraJobs.
1 contributor Edit on GitHub PHP

An early look at PHP 9.0's new features and changes

Table of contents:

An early look at PHP 9.0's new features and changes

Introduction

PHP is an open-source project. Knowing what new features and changes are planned for the next version only takes a minute of research. For instance, this page lists all the accepted RFCs for different versions of PHP.

That being said, despite PHP 9.0 being planned, no work have been started yet and we have to dig deeper.

When will PHP 9.0 be released?

For now, the release date of PHP 9.0 hasn’t been announced yet. This version is still far in the future. We could get PHP 8.5 and 8.6 before 9.0 is even considered. Who knows?

How to install and test PHP 9.0?

To this day, no work has been started on PHP 9.0, so you won’t even be able to pull the latest code and compile it yourself.

New features and changes planned for PHP 9.0

Deprecated features from earlier PHP versions will be removed

Features that have been deprecated in PHP 8.1, 8.2, 8.3, and 8.4 (learn more about PHP 8.4) will finally removed in PHP 9.0. This will translate to breaking changes for developers who ignored the warnings. 😅

Here’s a list of RFCs containing all the deprecated features:

Some warnings will become errors in PHP 9.0

In order to make PHP more reliable, warnings for undefined variables and properties will now become errors.

For instance, the following code will not run anymore in PHP 9.0:

// PHP 8.x: "Warning: Undefined variable $foo"
// PHP 9.0: "Fatal error: Uncaught Error: Undefined variable '$foo'"
echo $foo;

Also, from what I understand, these changes with variables and properties will make the maintainers’ lives easier, which is good for everyone!

I let you check out the RFCs for more details:

Benjamin Crozat

Written by Benjamin Crozat

Indie hacker, blogger, and AI enthusiast building things with the TALL stack. 🔥

Follow me on:

Recommended articles

PHP 8.3 is out, now! Here's what's new and changed. PHP 8.3 is out, now! Here's what's new and changed.

PHP 8.3 was released on November 23, 2023, and as usual, you need to be up to date with new features and breaking changes for easier transitions.

Modified on Nov 23, 2023

PHP
Methods with the same name as their class will not be constructors in a future version of PHP Methods with the same name as their class will not be constructors in a future version of PHP

Learn why and how to fix "Methods with the same name as their class will not be constructors in a future version of PHP" warnings.

Modified on Nov 23, 2022

PHP
PHP 8.4: new features and release date PHP 8.4: new features and release date

PHP 8.4 is expected to drop on November 21, 2024. Let's review the known new features and changes.

Modified on Nov 3, 2023

PHP
Is PHP dead? Usage statistics and market share for 2023. Is PHP dead? Usage statistics and market share for 2023.

Whether PHP is dead is a matter of numbers, not opinions. I will provide you with essential statistics that will lead you to make better decisions.

Modified on Sep 19, 2023

PHP
6 ways to check which version of PHP you are running 6 ways to check which version of PHP you are running

Discover how to check your version of PHP using phpinfo(), your terminal, Laravel's welcome page, or a Laravel Artisan command.

Published on Sep 2, 2023

Gold sponsors New

  • Wire Elements
    Beautiful handcrafted Livewire components.
    Check site
Your business here

Partners

If you buy from one of my partners below, I will be compensated at no cost to you. These are services I use or used, and 100% stand behind.

  • Scalable and reliable VPS hosting.
    Bonus: $200 of free credits
    Check site
  • The Google Analytics alternative without compromise.
    Free trial: 30 days
    Bonus: $10 off your first invoice
    Check site
  • Flare
    Track PHP and JavaScript errors in one place.
    Free trial: 10 days
    Check site
  • Keep track of your Google rankings.
    Free trial: 7 days
    Promo code: WELCOME30
    Check site
- / -