hi, On Wed, Jun 27, 2012 at 1:30 PM, Nikita Popov <nikita....@googlemail.com> wrote:
>> Why not in the spirit of others have a new function json_last_error_msg() or >> something similar? > > I implemented it with json_last_error(true) returning just a string, > not an array. You can get the array using array(json_last_error(), > json_last_error(true)) if you really want. But usually you will only > need one of them as they both have different use cases. The > stringified version for debugging and the error code version for > detecting the error programmatically. I do not think this signature is consistent with the other error functions. I'd to go with the _msg or _string equivalent. Cheers, -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php