Interface Default Methods

Read the RFC
95
168 yes
264 no

Interface Default Methods improves backwards compatibility when changing interfaces, but also add a way to have multi-inheritance in PHP.

Click the bar to cast your vote!
39%
61%
1

Sometimes a interface should have a sensible default/example.

Share:
jw avatar
jw
voted yes
1

Larry Garfield's comments here and here on the mailing list were convincing (read them!) But also every day I Ctrl+Click a method call, only to reach the interface instead of the implementation. More often than not, I'm looking for the implementation, so this slows me down. A default instead of a trait is less code, and smoother developer experience (DX).

Share:
francis avatar
francis
voted yes
1

Only if we deprecate traits, and move all traits features to interfaces

Share:
stanislav avatar
stanislav
voted no
1

would help to bring the language in line with what its already being done by interfaces and traits, but in a way that's integrated with the language and easier for tooling to peek into.

Share:
philip avatar
philip
voted yes
1

To me looks makes more sense to separate things.

Share:
tiago avatar
tiago
voted no

Check out another RFCs

Short Closures 2.0

This RFC proposes a way to have multi-line short closures — closures that don't need explicit use statements, but can still have multiple lines and a return statement.

101
373 yes
66 no
The Pipe Operator

The "pipe operator" |> allows you to chain multiple function calls in a more convenient way.

93
272 yes
131 no
new MyClass()->method() without parentheses

Chain method on newly created objects without parentheses

54
95 yes
16 no
RSS Feed Contribute Watch on YouTube Our License
© 2024 RFC Vote. This project is open source. Contribute and collaborate with us!