Stanislav Malyshev wrote on 16/02/2015 05:14:
Hi!

Agreed. Personally, I'm a great fan of symettry, so part of me would
prefer to introduce a keyword for when you *can't* call a method
statically, e.g. "instance function foo() { ... }". But I guess instance
This would be another form of saying "foo() method uses $this", but if
that's true then once it uses $this you'd get the error anyway, so not
much changes from adding "instance".


Well, no, it would mean "you cannot call this method statically, even if it doesn't use $this", i.e. the same meaning proposed for any method that omits the keyword "static". By your reasoning, you could say that adding "static" just means "foo() method doesn't use $this". The point is that you're making an explicit choice one way or another, and the version with neither annotation remains ambiguous.

Regards,
--
Rowan Collins
[IMSoP]

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to