Questions tagged [sequences]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
3
votes
2answers
151 views

mapcar but return non-nil element only

Is there a function that applies a transformation to a sequence and returns only the non-nil values? Right now I am using the following (as an example): (seq-filter #'identity (mapcar (lambda (x) ...
0
votes
1answer
36 views

Effective concatenation

How can I concatenate two sequences of lists (either lists of lists or vectors of lists) in constant time (independent of their size)?
1
vote
2answers
185 views

Filter list by regexps

How can I get all elements of a list which don't match multiple patterns? The patterns are given as a list. For instance, I want all files without '("no" "nix") in them. (setq se-...
2
votes
0answers
47 views

Do we have anaphoric macros of seq.el?

In dash.el, there are anaphoric macros (it saves to write "lambda": (--map (* it 2) '(1 2)) instead of (-map (lambda (it) (* it 2)) '(1 2))) seq.el is more generic, it works on strings and vectors ...
5
votes
1answer
119 views

Rings and sequences

I find it surprising that rings (from make-ring) are sequences (satisfy sequencep), but cannot be operated on by standard sequence functions (length, elt, etc.). What, then, does being a "sequence" ...
2
votes
3answers
286 views

How to check if a vector includes a value

When I want to know whether a list includes a value, I can use member function. (member "a" '("a" "ā" "á" "ǎ" "à")) Is there similar way to check if a vector includes a value? (member "a" ["a" "ā" "...