Do you wish that PHP had features that other languages have? Have you got some great ideas about how to extend PHP’s feature set but don’t want to go through the RFC process?
Great news. There is another way. It is possible to implement some new language features using static analysis and PHP code.
This talk will briefly introduce the PHP Language Extension library; which offers features such as Java’s package level visibility and C++’s friend feature. Then, we’ll take a deep dive into how to create a custom PHPStan rule.
By the end of the talk, hopefully you’ll be inspired to create your own enhancements to PHP, or at the very least have a starting point to write your own custom rules.


Comments are closed.

Interesting feature. You could "sell it" as a ready to use tool based on phpstan, similar to "doctrine extensions" for example. "Extending php language" sounds like a hussle, "I give you a ready-to-use tool" sound more appealing ;)