Re: emacs-31 429336b409e: Fix perl-calculate-indent
Stefan Monnier via "Emacs development discussions." <[email protected]>
| Newsgroups | gmane.emacs.devel |
|---|---|
| Message-ID | <[email protected]> |
Harald Jörg [2026-07-21 20:39:33] wrote: > Stefan Monnier writes: > >>> + (format (and (characterp (nth 3 state)) >>> (char-equal (nth 3 state) ?\n)))) >> >> (equal (nth 3 state) ?\n) ? > > It had occurred to me that this is could be another way to do it. But I > wasn't sure, and I could not break Petteri's solution. So, I simply ran > `git am` and kept it. > > Simply replacing `char-equal` with `equal` looks nice and would be even > less intrusive than the patch now applied to emacs-31. It makes the code simpler and more efficient (e.g. avoids the redundant `(nth 3 state)`). Also AFAIK the only reason to use `char-equal` over `eql/=/equal/eq` is to get case-insensitive equality, but I don't think it's something we need (or even want) when comparing with ?\n > If you want me to commit that, I'd be happy to do it I don't "want you to", really, it's just what I'd do if I were maintaining that code 🙂 === Stefan