Pure-perl JSON parser implementation