Re: Add a new flag for json_encode

From: Date: Wed, 05 Nov 2014 16:34:59 +0000
Subject: Re: Add a new flag for json_encode
References: 1 2 3 4 5  Groups: php.internals 
Request: Send a blank email to internals+get-78730@lists.php.net to get a copy of this message
On Wed, Nov 5, 2014 at 4:23 PM, Juan Basso <jrbasso@gmail.com> wrote: > > I also prefer to use ​different flags if we enable by default. So if this > behavior is enabled by default in 7.0 the JSON_PRESERVE_FRACTIONAL_PART > is deprecated and a new flag is created to disable it. > > In resume of this thread, seems everyone if fine in having the flag > JSON_PRESERVE_FRACTIONAL_PART > added on 5.6 and leave this flag off by default to keep the BC. The only > discussion is enable or not this behavior in 7.0. > No! If it should become default in 7.0, then it doesn't make to add a new flag. What's the point of adding new flag to 5.6.x and then deprecate it in 7.0...? That's just mess IMHO. It makes sense only if it doesn't become default though. Cheers Jakub

« previous php.internals (#78730) next »