GNU bug report logs -
#67390
28; shorthands-font-lock-shorthands assumes shorthand uses same separator
Previous Next
Full log
View this message in rfc822 format
On Wed, Nov 29, 2023 at 1:30 PM João Távora <joaotavora <at> gmail.com> wrote:
>
> On Sat, Nov 25, 2023 at 4:03 PM Jonas Bernoulli via Bug reports for
> GNU Emacs, the Swiss army knife of text editors
> <bug-gnu-emacs <at> gnu.org> wrote:
> >
> > Joseph Turner <joseph <at> ushin.org> writes:
> >
> > > + (car (shorthands--find-if
> > > + (lambda (short)
> > > + (string-prefix-p short (match-string 1)))
> > > + read-symbol-shorthands #'car)))))
> >
> > Or simply:
> > (car (assoc (match-string 1)
> > read-symbol-shorthands
> > #'string-prefix-p))
>
> I don't think it works, at least in my 'assoc', the order
> of string-prefix-p arguments must be switched. Pity
> assoc or string-prefix-p decs didn't coordinate this.
nevermind, it does work if what you want is to see if the cars
of the alist are prefixes to the key, which is probably your
intention in this snippet.
This bug report was last modified 1 year and 24 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.