Hi Rasmus, Am Montag, den 15.12.2008, 14:17 -0800 schrieb Rasmus Lerdorf: [...] > There has to be a way to do a basic type without any sort of error or > warning. E_STRICT, even if turned off, is slow. It ends up calling > php_verror to construct the entire error string before it checks and > sees that it isn't going to be written or displayed anywhere. That'd be > another thing to look at eventually, of course, but for now, sprinkling > the code with E_STRICT warnings in cases where there is a legitimate > case for the usage, is a really bad idea.
I agree - with both the optimization and about making it possible to encode scalars without any warning. So let's go with json_encode($value, $encodeScalar = false), document it for 5.3 and throw a warning, if json_encode(12, false) is called. cu, Lars -- Jabber: l...@strojny.net Weblog: http://usrportage.de
signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil