From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: JSON->lisp Mapping: Hash vs AList Date: Mon, 18 Dec 2017 22:19:29 +0200 Message-ID: <83k1xjpz5a.fsf@gnu.org> References: <838te5uvee.fsf@gnu.org> <838te1qrkq.fsf@gnu.org> <834lopqft0.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1513628489 14736 195.159.176.226 (18 Dec 2017 20:21:29 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 18 Dec 2017 20:21:29 +0000 (UTC) Cc: emacs-devel@gnu.org, raman@google.com To: Philipp Stephani Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 18 21:21:25 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eR1ud-0003QL-CE for ged-emacs-devel@m.gmane.org; Mon, 18 Dec 2017 21:21:23 +0100 Original-Received: from localhost ([::1]:38639 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eR1wb-0005lG-JD for ged-emacs-devel@m.gmane.org; Mon, 18 Dec 2017 15:23:25 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55718) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eR1sk-0002Kh-Em for emacs-devel@gnu.org; Mon, 18 Dec 2017 15:19:27 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eR1sg-0007Gz-0k for emacs-devel@gnu.org; Mon, 18 Dec 2017 15:19:26 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:44646) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eR1sf-0007Gq-Th; Mon, 18 Dec 2017 15:19:21 -0500 Original-Received: from [176.228.60.248] (port=1648 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1eR1sf-0004Le-4m; Mon, 18 Dec 2017 15:19:21 -0500 In-reply-to: (message from Philipp Stephani on Mon, 18 Dec 2017 19:55:52 +0000) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:221225 Archived-At: > From: Philipp Stephani > Date: Mon, 18 Dec 2017 19:55:52 +0000 > Cc: raman@google.com, emacs-devel@gnu.org > > @defun json-parse-string string &key (object-type @code{hash-table}) > > ? > > If that's the right thing, sure. OTOH, cl.texi uses > @defun cl-fill seq item @t{&key :start :end} > so probably we should use that? No, @t is almost never right, certainly not in code sequences. > > > > +The keyword argument OBJECT-TYPE specifies which Lisp type is used to > > > ^^^^^^^^^^^ > > > Shouldn't that be `:object-type' (including quotes)? > > > > > > Depending on whether we can use &key in a docstring in core. If so, then this one is correct, see > e.g. > > the > > > docstring of should-error. > > > > IMO, the doc string of should-error is no less confusing than this > > one, because it expects something like ":type 'foo". > > > > Arguably yes. Though that has been the convention for cl-lib functions for a while. > > cl-lib enjoyed being in the shadows for too long. I don't think we > should let that continue any longer, we should fix that. > > OK, what's your suggestion? I thought I wrote that above.