Re: Renaming type-hints to something else?
| From: | Sara Golemon | Date: | Wed, 17 Sep 2014 08:46:09 +0000 |
| Subject: | Re: Renaming type-hints to something else? | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-77280@lists.php.net to get a copy of this message | ||
> On Sep 16, 2014, at 8:11, Levi Morrison <levim@php.net> wrote:
> Can anyone come up with a better name than
hints? Maybe `type
> declarations? Or should we just stick with hints`?
My general feeling is to leave it alone. I agree that it's a misnomer, but as has been
mentioned, it's a well established misnomer. I don't see a big gain from it apart from
academic purity.
That, said, while I don't support a yes vote, I wouldn't bother voting against it.
I do worry about a small class of extensions which inspect type hints. They'll need to ifdef
around the API version to keep working. But I'll be honest, there's probably very few of
those, and I probably wrote a sizable portion of them out of boredom. Even if they're more
common than I imagine, the work-arounds are easy and reasonable, and anyone with a lick of C
knowledge can manage it in a few minutes.
As for Hint versus Declaration/Decl or Annotation or whatever... My second choice (since staying
with hint is my first) is probably decl(aration). Despite my HHVM loyalties, I'm not fond of
using "annotation" here anyway. There's a reasonable argument in this thread for
"check", but that feels clumsy from the user side.
-Sara (My .02 USD)