PSR-12 replacing PSR-2 instead of extending it

265 views
Skip to first unread message

Michael Cullum

unread,
Oct 11, 2015, 8:27:58 PM10/11/15
to FIG, PHP
So the idea has come up to simply replace PSR-2 with a new PSR that includes the stuff for the new functionality and Errata but instead of it being an extension, have it as a replacement (the difference being psr-2 content will be included in the PSR and PSR-2 will be marked as depreceated, what will go into PSR-12/be changed from PSR-2 will remain unchanged)

Phil [Sturgeon] and I were discussing this recently. I think this could potentially help adoption of PSR-12 (if PSR-2 is deprecated), it follows our bylaws a lot more cleanly and would make things a lot clearer in the smaller things where PSR-12 was offering clarification as specific instructions in PSR-2 were not numbered, only sections. So you have to say things such as "All PHP files MUST end with a single containing only a single newline (LF) character. This instruction supersedes that of relevant instructions within PSR-2, Section 2.2."

We can then provide a list of 'differences' in the meta document to aid tools in adding PSR-12 support, but this replacement instead of extension model will also make things easier to understand for any brand new tools that come out.

You can see a brief portion of the chat between me and Phil here: https://groups.google.com/d/msg/php-fig/O_vQUdOwHKA/isyS6GIoBQAJ

Thoughts?

--
Michael Cullum

Alexander Makarov

unread,
Oct 12, 2015, 5:41:54 AM10/12/15
to PHP Framework Interoperability Group
I support it.

Leo Feyer

unread,
Oct 12, 2015, 6:32:16 AM10/12/15
to php...@googlegroups.com
I like the idea of deprecating PRS-2 in favor of PSR-12. It will be a lot easier to understand then an old PSR with tons of amendments.

Cheers
Leo


signature.asc

Leo Feyer

unread,
Oct 12, 2015, 6:33:00 AM10/12/15
to php...@googlegroups.com
I meant „… a lot easier to understand _than_ an old PSR …“ of course :)

signature.asc
Reply all
Reply to author
Forward
0 new messages