On 6-Oct-06, at 12:17 PM, Stanislav Malyshev wrote:

I be wary of allowing this because in some instances method signature can drastically impact behavior for example foo(&$bar) {} vs foo($bar); I'd prefer to don't reduce this to E_NOTICE.

Yes, it can have runtime impact. So what? There are so many cases where, for example, not declaring a variable upfront or not assigning a type to it may change script behavior and even introduce a security hole. However, PHP is built to allow such things, and I do not think we should prohibit them - especially if there are a lot of valid uses for them. I think PHP should have priority on flexibility over strictness, if you prefer strict language you can always have Java and declare everything up to the last bit :)

On the same note you can use C and ignore all rules, coding using only void pointers and relying purely on gotos for flow control. :-)

You are talking about creating static class variables (dynamic ones can already be created without even an E_NOTICE). I think if you need this done, why not create a property dynamically and then access it statically? I suppose you are using this is a means of having a global

What do you mean by "creating dynamically and accessing statically"?

Bah never mind, confusing properties with methods, my mistake.

Ilia Alshanetsky

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

Reply via email to