From: Adam Porter <adam@alphapapa.net>
To: emacs-devel@gnu.org
Subject: Re: [ELPA] Want to submit two packages "ilist" and "blist"
Date: Sun, 19 Sep 2021 11:43:53 -0500 [thread overview]
Message-ID: <877dfc8qie.fsf@alphapapa.net> (raw)
In-Reply-To: m2zgs9rxbp.fsf@gmail.com
Durand <mmemmew@gmail.com> writes:
> The two packages can be found via the following links:
>
> <https://gitlab.com/mmemmew/ilist/>
> <https://gitlab.com/mmemmew/blist/>
By the way, I see in ilist.el this comment:
;; This is similar to using `cl-defstruct', but this struct is so
;; simple that depending on the cl library seems unnecessary to me.
You may not know that `cl' has been part of Emacs for over 30 years.
It's curious why some users seem to have an aversion to it. Somehow
there's this persistent myth that using it in a library would be not
minimalistic enough, yet cl-lib is used by Emacs's own code, so it's
loaded anyway, and its code is standard and reliable.
So rather than defining a number of aliases for a bespoke list format
like:
;;;; column accessors
(defalias 'ilist-column-name 'car
"Return the NAME of COLUMN.
\(fn COLUMN)")
(defalias 'ilist-column-fun 'cadr
"Return the FUN in COLUMN.
\(fn COLUMN)")
(defalias 'ilist-column-min 'caddr
"Return the MIN in COLUMN.
\(fn COLUMN)")
(defalias 'ilist-column-max 'cadddr
"Return the MAX in COLUMN.
\(fn COLUMN)")
;; Unfortunately (or not) there is no caddddr and cadddddr.
(defun ilist-column-align (column)
"Return the ALIGN in COLUMN."
(nth 4 column))
(defun ilist-column-elide (column)
"Return the ELIDE in COLUMN."
(nth 5 column))
It would be much more efficient and simple to just use cl-defstruct.
next prev parent reply other threads:[~2021-09-19 16:43 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-19 4:41 [ELPA] Want to submit two packages "ilist" and "blist" Durand
2021-09-19 10:15 ` Stefan Kangas
2021-09-20 8:39 ` Durand
2021-09-19 12:45 ` Stefan Monnier
2021-09-19 16:33 ` Adam Porter
2021-09-20 0:10 ` Durand
2021-09-20 1:56 ` Adam Porter
2021-09-19 16:43 ` Adam Porter [this message]
2021-09-19 23:40 ` Durand
2021-09-19 17:01 ` [External] : " Drew Adams
2021-09-19 23:59 ` Durand
2021-09-20 4:18 ` Drew Adams
2021-09-20 11:19 ` Durand
2021-09-20 15:25 ` Drew Adams
2021-09-20 23:48 ` Richard Stallman
2021-09-21 0:45 ` Durand
2021-09-20 23:47 ` Richard Stallman
2021-09-21 0:39 ` Durand
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=877dfc8qie.fsf@alphapapa.net \
--to=adam@alphapapa.net \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).