Home » Community » People » levim »
levim

levim

Contributor Directory

RFCs

Language and policy proposals from this contributor
RFCs are part of the process by which decisions are made about PHP. For more information about the RFC process as well as viewing a full list of RFCs please visit the RFC section.

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%)

reserve_more_types_in_php_7

Yes
No
Yes
40 Votes (95%)
No
2 Votes (5%)

Remove PHP 4 Constructors

Author
Target
7.0
PHP 4 constructors are methods that have the same name as the class they are defined in. PHP 5 preserved the ability to use PHP 4 style constructors in some cas...

remove_php4_constructors

Yes
No
Yes
50 Votes (93%)
No
4 Votes (7%)

Return Type Declarations

Author
Target
7.0
Many developers would like to be able to declare the return type of a function. The basic idea of declaring a return type has been included in at least three RF...

Typed Returns

Yes
No
Yes
47 Votes (94%)
No
3 Votes (6%)

Make defining multiple default cases in a switch a syntax error

Author
Target
7.0
Bug 67757 notes that the recently introduced PHP language specification differs from PHP's behavior when a switch statement defines multiple default cases. The...

switch.default.multiple

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

Remove type-restrictions on foreach keys?

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

Interface Default Methods

Author
Over time, authors sometimes want to add methods to an interface. Today, this causes large breakages to every implementor. This RFC proposes a way to reduce the...

Interface Default Methods

Yes
No
Yes
15 Votes (47%)
No
17 Votes (53%)

ReflectionType Improvements

Author
For PHP 7.0 the ReflectionType API was introduced in conjunction with return types. Its minimal API was intended to be the base for future improvements; this R...

Accept ReflectionType Improvements RFC?

Yes
No
Yes
5 Votes (38%)
No
8 Votes (62%)

Union Types

Author
PHP has type declarations which can be associated with function parameters or return values. These declarations perform two useful roles:

Merge union types

Yes
No
Yes
11 Votes (38%)
No
18 Votes (62%)

Replace ?QuestionMarkNullables by union | null

Yes
No
Yes
5 Votes (19%)
No
21 Votes (81%)

Include true/false types

Yes
No
Yes
5 Votes (18%)
No
23 Votes (82%)

Your Title Here

Author
In PHP 7.0, the assert statement received some enhancements. Notably, it added the ability to throw exceptions on failures (but off by ini default) and the code...

Enumerated Types

Author
Often programmers encounter data that is naturally represented as small finite set of exclusive values. Currently in PHP there is no convenient type-safe way to...

Intersection Types

Author
Sometimes multiple behaviors are necessary for a routine to be able to do its job but there is no common interface for those behaviors. Sometimes a common inter...