in reply to make duplicate JSON keys an error

I wanted to suggest to you to have a look at JSON parser as a single Perl Regex and adapt it to your needs but I cannot make it parse your example...

Replies are listed 'Best First'.
Re^2: make duplicate JSON keys an error
by sedusedan (Pilgrim) on Oct 26, 2013 at 12:28 UTC

    It's because in Randal's code some whitespaces are not allowed. Here's the version that allows more whitespaces and parses the above example: Regexp.pm (it'll soon be on CPAN as JSON::Decode::Regexp 0.03).

    Also, here's a version that checks for duplicate keys: Regexp.pm.