IRC channel logs

2022-05-31.log

back to list of logs

<lechner>rekado mwette: okay, thank you!
<apteryx>hello! why doesn't this match (ice-9 match): (match #(("a" . "b")) (#(((? string?) . (? string?)) ..1) "match"))
<apteryx>if the vector is replaced by a string, it works: (match '(("a" . "b")) ((((? string?) . (? string?)) ..1) "match"))
<apteryx>another puzzling (for me) example: (match #(("a" . "b") ("c" . "d") ("e" . "f")) (#(((? string?) . cdr) ...) cdr)) -> ("b" "d" "f")
<apteryx>but (match #(("a" . "b") ("c" . "d") ("e" . "f")) (#(((? string?) . cdr) ..1) cdr)) -> match error
<apteryx>clearly, there's one or more (3) inner patterns (pairs) to match, so why does it not match when using ..1 instead of ... ?
<apteryx>weird, simplified: (match #(1 2) (#(x ..1) x)) -> 1, but (match #(1 2 3) (#(x ..1) x)) -> match error
<apteryx>seems a bug
<daviid>apteryx: you might try to ask in #scheme as well, there are some match experts there as well ... [not sure you'll get an asnwer, but worth a try maybe ...]
<apteryx>I've written to guile-users; will try in #scheme, thanks for the tip
<apteryx>I've worked around it for now using ... instead of ..1 (and duplicating the pattern manually)
***Guest7325 is now known as yewscion
***Guest3456 is now known as chrislck
<chrislck>emacs users... what do you use for eglot for scheme-mode?
<dsmith-work>Hey Hi Howdy, Guilers
<dsmith-work>chrislck: eglot? Doesn't that require LSP? I don't think there is one available for Guile.
<dsmith-work>chrislck: Geiser is the usual emacs-guile interaction thingy
<stis>Hello guilers!