[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Lisp files that load cl-lib in problematical ways
From: |
Emanuel Berg |
Subject: |
Re: Lisp files that load cl-lib in problematical ways |
Date: |
Wed, 25 Oct 2023 05:11:21 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
Richard Stallman wrote:
> But if we let ourselves be a little more flexible, how about
> this solution: install this
>
> (while (string-match "\\W" abbrev pos)
> (or (memq (aref abbrev (match-beginning 0)) badchars)
> (push (aref abbrev (match-beginning 0)) badchars))
> (setq pos (1+ pos)))
>
> instead of the current code:
>
> (while (string-match "\\W" abbrev pos)
> (cl-pushnew (aref abbrev (match-beginning 0)) badchars)
> (setq pos (1+ pos)))
>
> A CL fan might say the latter is simpler [...]
Yes, but none of those codes are super-simple, to be fair,
are they?
BTW the CL case can be improved like this - if it isn't that
much simpler, then at least it is much neater, I'd say.
(while (string-match "\\W" abbrev pos)
(cl-pushnew (aref abbrev (match-beginning 0)) badchars)
(cl-incf pos) )
--
underground experts united
https://dataswamp.org/~incal
- Re: What's missing in ELisp that makes people want to use cl-lib?, (continued)
- Re: What's missing in ELisp that makes people want to use cl-lib?, Richard Stallman, 2023/10/31
- Re: Lisp files that load cl-lib in problematical ways, João Távora, 2023/10/29
- RE: [External] : Re: Lisp files that load cl-lib in problematical ways, Drew Adams, 2023/10/29
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, João Távora, 2023/10/29
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, Emanuel Berg, 2023/10/30
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, João Távora, 2023/10/30
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, Emanuel Berg, 2023/10/30
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, Emanuel Berg, 2023/10/30
- Re: [External] : Re: Lisp files that load cl-lib in problematical ways, Richard Stallman, 2023/10/31
- Re: Lisp files that load cl-lib in problematical ways, Richard Stallman, 2023/10/31
- Re: Lisp files that load cl-lib in problematical ways,
Emanuel Berg <=
- Re: Lisp files that load cl-lib in problematical ways, Eli Zaretskii, 2023/10/25
- Re: Lisp files that load cl-lib in problematical ways, Richard Stallman, 2023/10/25
- Re: Lisp files that load cl-lib in problematical ways, Eli Zaretskii, 2023/10/26
- Re: Lisp files that load cl-lib in problematical ways, Richard Stallman, 2023/10/24
Re: [External] : Re: Shrinking the C core, Arsen Arsenović, 2023/10/20