On Fri, Oct 3, 2014 at 1:00 PM, Arvids Godjuks <arvids.godj...@gmail.com>
wrote:

> Hello internals.
>
> I'm firmly against removing the "function" keyword. PHP is a dynamic
> language, that means that even using the latest most functional IDE's out
> there, finding the implementation is not always few clicks away (PhpStorm's
> "Find Usages") and you need to do a search in the project. And the only
> thing, that makes it fast and easy, is the "function" keyword, because you
> can do a search by "function nameISearchFor" and get a single hit.
>
> I'm not even mentioning the code readability...
>

While there are reasonable arguments to be made for removing it, I agree
that it would create more problems than it would solve.  Specifically, one
of the things I've always liked about PHP is that I can always track down a
particular method declaration in a codebase by simply doing a grep for the
word "function" preceding the name.  If it's defined in that codebase,
it'll come up.  Even making the keyword optional would eliminate that
certainty and make it that much more difficult to navigate an unfamiliar
codebase.

--Kris

Reply via email to