Mercurial > hg > xemacs-beta
comparison tests/automated/lisp-tests.el @ 5034:1b96882bdf37
Fix a multiple-value bug, mapcarX; correct a comment and a label name.
src/ChangeLog addition:
2010-02-19 Aidan Kehoe <kehoea@parhasard.net>
* fns.c (mapcarX):
Correct this function, discarding multiple values when one
SEQUENCE is supplied, choosing a better label name. Correct the
comment describing the SOME_OR_EVERY argument.
tests/ChangeLog addition:
2010-02-19 Aidan Kehoe <kehoea@parhasard.net>
* automated/lisp-tests.el:
Check that multiple values are discarded correctly with #'mapcar
and one SEQUENCE.
author | Aidan Kehoe <kehoea@parhasard.net> |
---|---|
date | Fri, 19 Feb 2010 23:21:27 +0000 |
parents | 6ef8256a020a |
children | b1e48555be7d |
comparison
equal
deleted
inserted
replaced
5033:d2c3bac89ba0 | 5034:1b96882bdf37 |
---|---|
970 "Devious evil mapping function" | 970 "Devious evil mapping function" |
971 (when (eq (car y) 1) | 971 (when (eq (car y) 1) |
972 (setcdr (cdr x) 42)) ; drop a brick wall onto the freeway | 972 (setcdr (cdr x) 42)) ; drop a brick wall onto the freeway |
973 (car y)) | 973 (car y)) |
974 x))) | 974 x))) |
975 | |
976 (Assert-eql | |
977 (length (multiple-value-list | |
978 (car (mapcar #'(lambda (argument) (floor argument)) (list pi e))))) | |
979 1 | |
980 "checking multiple values are correctly discarded in mapcar") | |
975 | 981 |
976 ;;----------------------------------------------------- | 982 ;;----------------------------------------------------- |
977 ;; Test vector functions | 983 ;; Test vector functions |
978 ;;----------------------------------------------------- | 984 ;;----------------------------------------------------- |
979 (Assert-equal [1 2 3] [1 2 3]) | 985 (Assert-equal [1 2 3] [1 2 3]) |