Hi Andrea,
On Thu, Nov 21, 2013 at 6:53 AM, Andrea Faulds wrote:
On 20/11/13 21:49, Andrea Faulds wrote:

Just my 2 cents, but that definitely looks like a situation that might
crop up in real code unintentionally, and it violates the Principle of
Least Astonishment IMO. Consider a hypothetical function which returns a
modified string. If we've ended up with an empty string being passed
into it, then it suddenly returning an Array is not what you expect, and
might horribly break code that assumes the result won't be a string.
Oh dear Andrea, you should proofread your emails better.
s/won't be/will be

I agree with your discussion and that's the reason why I sending
this PR before I said "it's the spec".

I've added this behavior to RFC (NOT for voting)

I'm gathering these kind of PHP behaviors. If you have one, please let me
know so that I can add issues in the wiki page. (Or even better, please add
one to the page)

Thank you.

Yasuo Ohgaki

Search Discussions

Discussion Posts


Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 7 of 10 | next ›
Discussion Overview
groupphp-internals @
postedNov 19, '13 at 11:48p
activeNov 22, '13 at 1:44a



site design / logo © 2022 Grokbase