Indeed, it seems your right - if I namespace the thing, the compiler
actually tells me that namespace/int is not the same as int. So yeah, it
probably assumes a type int here, which has no relation to the built-in
scalar int.

D'oh.

I didn't realize until know that one wasn't allowed to use type hints with
scalar types (int, string, bool, etc.) until PHP7. This explains a lot.

On Mon, Apr 17, 2017 at 9:33 PM Stas Malyshev <[email protected]>
wrote:

> Hi!
>
> > So, if I start a fresh MediaWiki Vagrant installation, and the vagrant
> ssh
> > into the virtual machine, the fastest way to reproduce the issue is to
> > start hhvmsh and type
> >
> > function f():int { return 1; };
>
> Suspicion: HHVM thinks "int" is a class name, not primitive type name.
> Not sure why though...
>
> --
> Stas Malyshev
> [email protected]
>
> _______________________________________________
> Wikitech-l mailing list
> [email protected]
> https://lists.wikimedia.org/mailman/listinfo/wikitech-l
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to