Open RFCs

Bound-Erased Generic Types

This RFC adds generic type syntax to PHP. Classes, interfaces, traits, functions, methods, closures, and arrow functions can declare type parameters; those parameters carry bounds, defaults, and variance markers; type arguments may be supplied at use sites and at call sites via turbofish.

93% 7%
36
55 yes
4 no
Asymmetric Visibility v2

A new syntax for declaring the “set” operation visibility of an object property

34% 66%
23
21 yes
40 no
new MyClass()->method() without parentheses

Chain method on newly created objects without parentheses

86% 14%
55
97 yes
16 no

Argument of the Day

2

in the syntax function identity<T>(T $value): T { return $value; }

why adding a <T>. we already have info of type of param in param list and type of return after the :

Share:
Read the RFC: Bound-Erased Generic Types eldy avatar
eldy
voted no
RSS Feed Contribute Watch on YouTube Our License
© 2026 RFC Vote. This project is open source. Contribute and collaborate with us!