help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to test for native JSON support?


From: Eli Zaretskii
Subject: Re: How to test for native JSON support?
Date: Tue, 04 May 2021 15:16:03 +0300

> From: Tim Landscheidt <tim@tim-landscheidt.de>
> Date: Tue, 04 May 2021 11:40:41 +0000
> 
> Nikolay Kudryavtsev <nikolay.kudryavtsev@gmail.com> wrote:
> 
> > json-serialize would return nil if libjansson library is not
> > available during the execution time. So the scenario would
> > be someone building Emacs with json support, then forgetting
> > to put libjansson on his path and/or moving the binary to
> > another machine. Not very likely to happen on any POSIX
> > systems, but a more or less tangible case on Windows.
> 
> That's a rather unexpected, at least undocumented failure
> mode (vulgo: a bug).  IMNSHO in that case json-serialize
> should either "work" or throw an error.

It actually displays an error message, in addition to returning nil
(as do all other JSON primitives in that case).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]