On 17/06/2026 13:30, fennic log wrote:
I would be fully in favour of this RFC, but there is 1 hurdle which cant
be ignored.
What should the PHP naming convention be for these?
Without deciding on what it should be we would be creating a new issue
of mix-mash of uppercase, lowercase and camelcase classes for example
Few examples
- DateTime is documented as Camelcase - https://www.php.net/manual/en/
class.datetime.php <https://www.php.net/manual/en/class.datetime.php>
- PDO is documented as uppercase - https://www.php.net/manual/en/
class.pdo.php <https://www.php.net/manual/en/class.pdo.php>
- mysqli is documentated as lowercase - https://www.php.net/manual/en/
set.mysqlinfo.php <https://www.php.net/manual/en/set.mysqlinfo.php>
- ArrayAccess is documented as camelcase - https://www.php.net/manual/
en/class.arrayaccess.php <https://www.php.net/manual/en/
class.arrayaccess.php>
PHP mixing case of definitions, at least with current system, users can
choose their preferred convention and it will work.
If we change to be case sensitive, we risk introducing a giant headache
for devs, as they need to remember what different casing each different
builtin class is.
It will become a the new `($haystack, $needle)` - `($needle, $haystack)`
problem, and won't gain love from the community.
There are already policies for that:
https://github.com/php/policies/blob/main/coding-standards-and-naming.rst
As for the existing stuff that you mention, we already have this casing
salad anyway even if we simply follow IDE autocomplete
--
Anton