GNU bug report logs -
#66057
(ice-9 match) allows invalid usages of ... or ..1
Previous Next
Full log
View this message in rfc822 format
Hi,
After attempting the following:
--8<---------------cut here---------------start------------->8---
(match (string-split "./Bootloaders/Printer/Documentation/html" #\/)
(("." path ..1 "Documentation" "html")
(pk 'path path)))
=> ;;; (path "Bootloaders")
Expected (and works with '...'):
;;; (path "Bootloaders" "Printer")
--8<---------------cut here---------------end--------------->8---
and asking about it in #scheme or #guile, it seems the '..1' and '...'
patterns *must* be used strictly to match at the end of lists, but this
isn't explicitly mentioned in the manual, and even works for ... but not
for ..1, which is inconsistent/econfusing.
It was suggested by Zipheir in #scheme that Guile should return a syntax
error when ..1 or ... are used somewhere else than at the end of a list.
It seems a good suggestion.
--
Thanks,
Maxim
This bug report was last modified 1 year and 269 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.