GNU bug report logs - #32793
27.0.50; json-parse-string doesn't have the equivalent of json.el's json-array-type

Previous Next

Package: emacs;

Reported by: Xu Chunyang <mail <at> xuchunyang.me>

Date: Fri, 21 Sep 2018 12:58:01 UTC

Severity: minor

Found in version 27.0.50

Done: Dmitry Gutov <dgutov <at> yandex.ru>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 32793 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dmitry Gutov <dgutov <at> yandex.ru>
Cc: mail <at> xuchunyang.me, 32793 <at> debbugs.gnu.org
Subject: Re: bug#32793: 27.0.50;
 json-parse-string doesn't have the equivalent of json.el's
 json-array-type
Date: Thu, 11 Apr 2019 19:46:14 +0300
> From: Dmitry Gutov <dgutov <at> yandex.ru>
> Date: Thu, 11 Apr 2019 19:26:23 +0300
> 
> On 21.09.2018 15:56, Xu Chunyang wrote:
> 
> > We can parse JSON Array as Lisp List with json.el, e.g.,
> > 
> > (let ((json-array-type 'list))
> >    (json-read-from-string "[1,2,3]"))
> > ;; => (1 2 3)
> > 
> > but the new json-parse-string doesn't have the equivalent, thus porting
> > existing code to using json-parse-string might be difficult.
> 
> I also stumbled on this problem when trying to port existing code to 
> native JSON.

Sounds like a simple extension of the existing code, so patches are
welcome to implement this feature.




This bug report was last modified 6 years and 99 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.