Re: Split as an alias to explode
| From: | Christian Schneider | Date: | Mon, 18 Aug 2025 14:16:16 +0000 |
| Subject: | Re: Split as an alias to explode | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-128502@lists.php.net to get a copy of this message | ||
Am 18.08.2025 um 15:36 schrieb Rowan Tommins [IMSoP] <imsop.php@rwec.co.uk>:
> A developer coming to PHP from any combination of JavaScript, Perl, C#, Java, VisualBasic,
> Python, Ruby, Swift, Elixir, Dart, Rust, even Excel ... is going to look first for a function called
> "split" or some variation of that. If they have any common sense, they'll know they
> need to look up exactly what arguments it needs, and what options it provides.
I don't think people nowadays search through documentation for a specific function name.
I am pretty confident that people will either Google/DDG/... or ask an AI chat something like
"How do I split a string in PHP?" which gives a complete code example including parameter
order.
> If we don't want to add an alias, we should probably add a fake manual entry pointing
> people in the right direction, like we have for "delete":
> https://www.php.net/delete
This would IMHO be better suited for a tutorial / learning website, I am not convinced that we need
to extend the reference documentation (or even the language) with entries of synonyms/aliases people
might be looking for.
So, in short, that's a -1 for a split alias from me.
Regards,
- Chris