1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-20 18:17:20 +00:00

(last): Handle a list that doesn't end in nil.

This commit is contained in:
Richard M. Stallman 2001-01-12 19:51:09 +00:00
parent 420198cbe2
commit 6bfdc2e29f

View File

@ -131,7 +131,7 @@ If N is bigger than the length of X, return X."
(setq m (1+ m) p (cdr p)))
(if (<= n 0) p
(if (< n m) (nthcdr (- m n) x) x)))
(while (cdr x)
(while (consp (cdr x))
(setq x (cdr x)))
x))