Implemented in PHP 7.4

RFC Categories

    Deprecations for PHP 7.4

    Author
    Author
    Target
    7.4
    The RFC proposes to deprecate the listed functionality in PHP 7.4 and remove it in PHP 8.

    Deprecate (real) cast and is_real() function?

    Yes
    No
    Yes
    35 Votes (83%)
    No
    7 Votes (17%)

    Deprecate get_magic_quotes_gpc() and get_magic_quotes_runtime()?

    Yes
    No
    Yes
    46 Votes (100%)
    No
    0 Votes (0%)

    Deprecate array_key_exists() with objects?

    Yes
    No
    Yes
    44 Votes (100%)
    No
    0 Votes (0%)

    Deprecate FILTER_SANITIZE_MAGIC_QUOTES?

    Yes
    No
    Yes
    45 Votes (100%)
    No
    0 Votes (0%)

    Deprecate Reflection export() methods?

    Yes
    No
    Yes
    37 Votes (90%)
    No
    4 Votes (10%)

    Deprecate mb_strrpos() with encoding as 3rd argument?

    Yes
    No
    Yes
    44 Votes (100%)
    No
    0 Votes (0%)

    Deprecate implode() with inverted parameter order?

    Yes
    No
    Yes
    38 Votes (88%)
    No
    5 Votes (12%)

    Deprecate unbinding of $this from non-static closures?

    Yes
    No
    Yes
    43 Votes (100%)
    No
    0 Votes (0%)

    Deprecate hebrevc() function?

    Yes
    No
    Yes
    34 Votes (83%)
    No
    7 Votes (17%)

    Deprecate convert_cyr_string() function?

    Yes
    No
    Yes
    25 Votes (78%)
    No
    7 Votes (22%)

    Deprecate money_format() function?

    Yes
    No
    Yes
    34 Votes (81%)
    No
    8 Votes (19%)

    Deprecate ezmlm_hash() function?

    Yes
    No
    Yes
    37 Votes (90%)
    No
    4 Votes (10%)

    Deprecate restore_include_path() function?

    Yes
    No
    Yes
    31 Votes (78%)
    No
    9 Votes (23%)

    Deprecate allow_url_include ini option?

    Yes
    No
    Yes
    43 Votes (100%)
    No
    0 Votes (0%)

    Unbundle ext/recode

    Author
    cmb
    Target
    7.4
    ext/recode facilitates conversion between different character sets/encodings. This functionality is basically already supported by ext/iconv and ext/mbstring. ...

    Unbundle ext/recode

    Yes
    No
    Yes
    38 Votes (100%)
    No
    0 Votes (0%)

    Escape PDO "?" parameter placeholder

    Author
    Target
    7.4
    PostgreSQL, and possibly other databases, allow the usage of the question mark (?) character in operators, either alone or part of a multi-character operator. I...

    Add ?? as a way to escape ? in PDO parametrised queries?

    Yes
    No
    Yes
    27 Votes (93%)
    No
    2 Votes (7%)

    base_convert changes

    Author
    Scott Dutton
    Target
    7.4
    The base_convert family of functions(base_convert, binhex, hexbin etc) are very accepting with their input arguments, you can pass any string to to them and the...

    Raise deprecated error in 7.4 and raise to exception in PHP 8 for unknown characters

    Yes
    No
    Yes
    28 Votes (97%)
    No
    1 Votes (3%)

    Allow negative numbers to be converted in PHP 8

    Yes
    No
    Yes
    2 Votes (11%)
    No
    17 Votes (89%)

    Numeric Literal Separator

    Author
    Theodore Brown
    Author
    Target
    7.4
    The human eye is not optimized for quickly parsing long sequences of digits. Thus, a lack of visual separators makes it take longer to read and debug code, and ...

    Support numeric literal separator in PHP 7.4?

    Yes
    No
    Yes
    33 Votes (75%)
    No
    11 Votes (25%)

    Allow throwing exceptions from __toString()

    Author
    Target
    7.4
    Throwing exceptions from __toString() is currently forbidden and will result in a fatal error. This makes it dangerous to call arbitrary code inside __toString(...

    Allow exceptions from __toString() in PHP 7.4?

    Yes
    No
    Yes
    42 Votes (100%)
    No
    0 Votes (0%)

    Deprecate left-associative ternary operator

    Author
    Target
    7.4
    Unlike most (all?) other languages, the ternary operator in PHP is left-associative rather than right-associative. The left-associative behavior is generally no...

    Deprecate and remove left-associative ternary without explicit parentheses?

    Yes
    No
    Yes
    35 Votes (78%)
    No
    10 Votes (22%)

    Provide argon2i(d) implementations for password_hash() from ext/sodium

    Author
    Target
    7.4
    If PHP core was built without libargon, then password_hash() and family will not support the argon2i and argon2id hashing mechanisms. Since Password Hash Regis...

    Provide argon2i(d) from ext/sodium when argon not present

    Yes
    No
    Yes
    30 Votes (100%)
    No
    0 Votes (0%)

    Change the precedence of the concatenation operator

    Author
    Bob Weinand
    Target
    7.4
    It's been a long standing issue that an (unparenthesized) expression with '+', '-' and '.' evaluates left-to-right.

    Change the precedence of the concatenation operator as proposed in PHP 8?

    Yes
    No
    Yes
    31 Votes (89%)
    No
    4 Votes (11%)

    Emit a deprecation notice in PHP 7.4 if the RFC is accepted?

    Yes
    No
    Yes
    30 Votes (81%)
    No
    7 Votes (19%)

    Unbundle ext/interbase

    Author
    Target
    7.4
    The InterBase extension for PHP (ext/interbase) is one of the oldest database extension who currently resides in the Core. The extension allow access to InterBa...

    Move ext/interbase to PECL

    Yes
    No
    Yes
    46 Votes (100%)
    No
    0 Votes (0%)

    Deprecate curly brace syntax for accessing array elements and string offsets

    Author
    Andrey Gromov
    Author
    Theodore Brown
    Target
    7.4
    PHP allows both square brackets and curly braces to be used interchangeably for accessing array elements and string offsets. For example:

    Deprecate curly brace array and string offset syntax in PHP 7.4

    Yes
    No
    Yes
    37 Votes (86%)
    No
    6 Votes (14%)

    Arrow Functions 2.0

    Author
    Target
    7.4
    Anonymous functions in PHP can be quite verbose, even when they only perform a simple operation. Partly this is due to a large amount of syntactic boilerplate, ...

    Add arrow functions as described in PHP 7.4?

    Yes
    No
    Yes
    51 Votes (86%)
    No
    8 Votes (14%)

    New custom object serialization mechanism

    Author
    Target
    7.4
    PHP currently provides two mechanisms for custom serialization of objects: The __sleep()/__wakeup() magic methods, as well as the Serializable interface. Unfort...

    Include proposed serialization mechanism in PHP 7.4?

    Yes
    No
    Yes
    20 Votes (74%)
    No
    7 Votes (26%)

    Reflection for references

    Author
    Target
    7.4
    Specialized libraries that perform operations like dumping, cloning or comparison over arbitrary value graphs require the ability to reason about PHP references...

    Add ReflectionReference?

    Yes
    No
    Yes
    30 Votes (97%)
    No
    1 Votes (3%)

    mb_str_split

    Author
    rumi
    Target
    7.4
    mb_str_split is a function to perform string splitting to an array of defined size chunks.

    Include mb_str_split into next PHP-7.x?

    Yes
    No
    Yes
    10 Votes (91%)
    No
    1 Votes (9%)

    FFI - Foreign Function Interface

    Author
    Dmitry Stogov
    Target
    7.4
    FFI is one of the features that made Python and LuaJIT very useful for fast prototyping. It allows calling C functions and using C data types from pure scriptin...

    Include FFI extension into PHP-7.4 (bundle)?

    Yes
    No
    Yes
    24 Votes (62%)
    No
    15 Votes (38%)

    Improve openssl_random_pseudo_bytes()

    Author
    Target
    7.4
    The openssl_random_pseudo_bytes() function is a wrapper for OpenSSL's RAND_bytes CSPRNG. CSPRNG implementations should always fail closed, but openssl_random_ps...

    Make openssl_random_pseudo_bytes() fail closed

    Yes
    No
    Yes
    30 Votes (100%)
    No
    0 Votes (0%)

    Deprecate the usage of the $crypto_strong parameter

    Yes
    No
    Yes
    12 Votes (50%)
    No
    12 Votes (50%)

    Preloading

    Author
    Dmitry Stogov
    Target
    7.4
    PHP has been using opcode caches for ages (APC, Turck MMCache, Zend OpCache). They achieve significant performance boost by ALMOST completely eliminating the ov...

    Include preloading ability into PHP-7.4

    Yes
    No
    Yes
    48 Votes (100%)
    No
    0 Votes (0%)

    Password Hashing Registry

    Author
    Target
    7.4
    The password_*() functions introduced a means to support standardized password hashing mechanisms for use by applications. Support for bcrypt was included in th...

    Make the password hashing system extensible via internal-only registry?

    Yes
    No
    Yes
    21 Votes (100%)
    No
    0 Votes (0%)

    Support integer constants 0-3 to password_hash() et. al. for BC

    Yes
    No
    Yes
    19 Votes (95%)
    No
    1 Votes (5%)

    Spread Operator in Array Expression

    Author
    Target
    7.4
    PHP has already supported argument unpacking (AKA spread operator) since 5.6. This RFC proposes to bring this feature to array expression.

    Support spread operator for array definition in PHP 7.4?

    Yes
    No
    Yes
    43 Votes (98%)
    No
    1 Votes (2%)

    Covariant Returns and Contravariant Parameters

    Author
    Target
    7.4
    Currently PHP has mostly invariant parameter types and mostly invariant return types. This means that if a method of a super-type has a parameter or return type...

    Accept Covariant Returns and Contravariant Parameters?

    Yes
    No
    Yes
    39 Votes (98%)
    No
    1 Votes (3%)

    RFC: Always available hash extension

    Author
    Target
    7.4
    This RFC proposes to make the hash extension (`ext/hash`) always available, similar to the `date`, `spl` & `pcre` extensions.

    Make the hash extension always available as described in this RFC?

    Yes
    No
    Yes
    30 Votes (100%)
    No
    0 Votes (0%)

    Typed Properties 2.0

    Author
    Author
    Target
    7.4
    With the introduction of scalar types and return types, PHP 7 greatly increased the power of PHP's type system. However, it is currently not possible to declare...

    Add support for typed properties as described in this RFC?

    Yes
    No
    Yes
    70 Votes (99%)
    No
    1 Votes (1%)

    Weak References

    Author
    krakjoe
    Target
    7.4
    Weak References allow the programmer to retain a reference to an object which does not prevent the object from being destroyed; They are useful for implementing...

    Implement weakrefs ?

    Yes
    No
    Yes
    28 Votes (85%)
    No
    5 Votes (15%)

    Unbundle ext/wddx

    Author
    cmb
    Target
    7.4
    WDDX has been designed as programming language independent data exchange format for the web1). However, it never has been formally standardized, and it appears ...

    Unbundle ext/wddx

    Yes
    No
    Yes
    30 Votes (100%)
    No
    0 Votes (0%)

    Unbundle ext/wddx details

    depr. 7.4/move 8.0(1)
    depr. and move 7.4(2)
    move 7.4(3)
    dump 7.4(4)
    depr. 7.4/move 8.0(1)
    4 Votes (14%)
    depr. and move 7.4(2)
    19 Votes (68%)
    move 7.4(3)
    2 Votes (7%)
    dump 7.4(4)
    3 Votes (11%)

    E_WARNING for invalid container read array-access

    Author
    David Walker
    Target
    7.4
    PHP current array-access system works very well when attempting to access containers of type array, reference(to an array), and objects that implement ArrayAcce...

    E_WARNING for invalid container read array-access

    Yes
    No
    Yes
    19 Votes (83%)
    No
    4 Votes (17%)

    Null Coalescing Assignment Operator

    Author
    Midori Kocak
    Target
    7.4
    Combined assignment operators have been around since 1970's, appearing first in the C Programming Language. For example, $x = $x + 3 can be shortened to $x += ...

    Approve Equal Null Coalesce Operator RFC and merge patch into master?

    Yes
    No
    Yes
    37 Votes (90%)
    No
    4 Votes (10%)