http://qs1969.pair.com?node_id=1058769


in reply to Re: JSON parser as a single Perl Regex
in thread JSON parser as a single Perl Regex

Strangely enough, this project needed both YAML parsing and JSON parsing (don't ask!). I was able to cannibalize the YAML::Tiny, but I didn't find a similar module for JSON. I started writing a traditional recursive descent parser, and then I remembered that modern regex can do it all internally, so I took a whack at it. You see the result.

-- Randal L. Schwartz, Perl hacker

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.

  • Comment on Re^2: JSON parser as a single Perl Regex

Replies are listed 'Best First'.
Re^3: JSON parser as a single Perl Regex
by sedusedan (Monk) on Oct 19, 2013 at 03:38 UTC
    My point is, JSON::PP was perfectly cannibalizable at that point. But I understand that you probably thought it was a chance to do something cool.
      I've since looked at JSON::PP, and it's a lot more code. I like my approach better.

      -- Randal L. Schwartz, Perl hacker

      The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.