Hi

On 4/19/24 20:47, Bilge wrote:
Not that my opinion counts for much, but I have to say I find this very odd.

Good class names:
Id // Identifier
ID // Identity Document

I understand the distinction you wish to make here, between an acronym
and abbreviation, but I think it's a meaningless distinction. In this
case, `Id` would be fine for "identifier", but "Identity Document"
should simply be `IdentityDocument`. Whilst the distinction may seem
meaningful to you, it certainly does not look that way to me; I think it
would be difficult to remember and explain to someone else. Perhaps the
tie breaker could be that it wouldn't be meaningful to an automated
style checker, either. That is, it would be difficult to enforce this
policy exception in any automated way. Why not just keep it simple and
consistent here, disallowing runs of multiple upper-case letters?

I have copied the example identifiers verbatim from the existing phrasing in CODING_STANDARDS.md and just moved them into the correct section according to the updated wording.

However 'ID' as-in 'Identity Document' should also be 'Id' with the updated policy, which I missed. Or rather it should not be abbreviated at all.

I've adjusted the examples [1], thank you for pointing this out!

Best regards
Tim Düsterhus

[1] https://wiki.php.net/rfc/class-naming-acronyms?do=diff&rev2%5B0%5D=1712419286&rev2%5B1%5D=1713553737&difftype=sidebyside

Reply via email to