[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Code for cond*
|
From: |
Stefan Monnier |
|
Subject: |
Re: Code for cond* |
|
Date: |
Wed, 24 Jan 2024 12:08:21 -0500 |
|
User-agent: |
Gnus/5.13 (Gnus v5.13) |
>> returns the same `(foo moo loo . boo)`, so there is not a unique way for
>> a pattern like `(,@list-var . ,other) to match a given list.
>> That's a large part of the reason why ,@ is not supported in Pcase's
>> backquote patterns.
> Not a unique way without a policy, but could it not take the largest
> possible list at that position, ala regexp greedy matching?
Of course, if you absolutely want that feature, you can define a meaning
for it. But it does make it somewhat different in nature to the rest of
the patterns. Another difference is that it will allocate new objects
rather than just select fields from the object under scrutiny.
BTW, this is all implementable right now without any change to
`pcase.el`: just write the corresponding `pcase-defmacro` :-)
Stefan
- Re: Code for cond*, (continued)
Re: Code for cond*, Richard Stallman, 2024/01/19
Re: Code for cond*, Stefan Monnier, 2024/01/23
- Re: Code for cond*, JD Smith, 2024/01/23
- Re: Code for cond*, Stefan Kangas, 2024/01/24
- Re: Code for cond*, JD Smith, 2024/01/24
- Re: Code for cond*, Stefan Monnier, 2024/01/24
- Re: Code for cond*, Stefan Monnier, 2024/01/24
- Re: Code for cond*, JD Smith, 2024/01/24
- Re: Code for cond*,
Stefan Monnier <=
- RE: [External] : Re: Code for cond*, Drew Adams, 2024/01/24
RE: [External] : Re: Code for cond*, Drew Adams, 2024/01/24
Re: Code for cond*, Madhu, 2024/01/25
Re: Code for cond*, Stefan Monnier, 2024/01/25
Re: Code for cond*, JD Smith, 2024/01/25
Re: Code for cond*, JD Smith, 2024/01/25
Re: Code for cond*, Alfred M. Szmidt, 2024/01/25
Re: Code for cond*, JD Smith, 2024/01/25
Re: Code for cond*, Stefan Monnier, 2024/01/25
Re: Code for cond*, Alfred M. Szmidt, 2024/01/25