Skip Menu |

This queue is for tickets about the JSON-PP CPAN distribution.

Report information
The Basics
Id: 108384
Status: new
Priority: 0/
Queue: JSON-PP

People
Owner: Nobody in particular
Requestors: alex.karelas [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Feature request: allow encoding of \'' (=false)
Date: Mon, 2 Nov 2015 18:25:57 +0200
To: bug-JSON-PP [...] rt.cpan.org
From: Alexander Karelas <alex.karelas [...] gmail.com>
I often find myself writing JSON::PP->encode({flag => $expr ? \1 : \0}); ...or allternatively: {flag => \(!!$expr + 0)}; It would be better and simpler if we could just write instead JSON::PP->encode({flag => \!!$expr}); ...like we can do with the Mojo::JSON module.