mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2026-01-23 04:52:42 -08:00
compiler: fix compiler-macro for `FIND'
C-compiled `FIND' didn't respect `START' nor `END' arguments due to bug in parsing the arguments and invoking `DO-SEQ'. Fixes #199.
This commit is contained in:
parent
f49fd1ea81
commit
af9900c7d4
2 changed files with 7 additions and 2 deletions
|
|
@ -119,6 +119,9 @@
|
|||
- Fix `listen' on streams when FILE_CNT isn't available (use read instad
|
||||
of fread)
|
||||
|
||||
- `FIND' compiled with C compiler didn't respect `START' nor `END'
|
||||
arguments. Compiler macro is fixed now and should work as expected
|
||||
|
||||
* 16.0.0 changes since 15.3.7
|
||||
** API changes
|
||||
|
||||
|
|
|
|||
|
|
@ -101,7 +101,9 @@
|
|||
(nconc key-init test-init)
|
||||
key-flag
|
||||
test-flag
|
||||
test))))))
|
||||
test
|
||||
start
|
||||
end))))))
|
||||
|
||||
#+(or)
|
||||
(define-compiler-macro si::make-seq-iterator (seq &optional (start 0))
|
||||
|
|
@ -275,7 +277,7 @@
|
|||
(ext:with-unique-names (%value %elt)
|
||||
`(let ((,%value ,value)
|
||||
,@init)
|
||||
(do-in-seq (,%elt ,sequence)
|
||||
(do-in-seq (,%elt ,sequence :start ,start :end ,end)
|
||||
(when ,(funcall test-function %value
|
||||
(funcall key-function %elt))
|
||||
(return ,%elt))))))))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue