Hacker News new | ask | show | jobs
by xellisx 2021 days ago
I want structs and static classes (OK, the last one isn't really needed, just more about being a stickler).
1 comments

Static class is probably the best solution for having namespaced functions combined with having auto loading working correctly.

Structs would be great too, especially if PHP could support inner class definitions.

I started on some RFCs, but due to life events, I don't have time to finish them out.

https://github.com/ellisgl/PHP-RFC-Struct-Data-Type

https://github.com/ellisgl/PHP-RFC-Static-Class-Type

[edit: spelling]