BUTLAST counts conses before copying whole list
BUTLAST counts the conses of the argument list before checking if n is zero, in which case the entire list will be copied. The zerop check can be done before counting the conses, as in NBUTLAST. Also, the similar cases of BUTLAST and NBUTLAST can be made clearer.
Regression tests already exist in tests/list.
|Changed in sbcl:|
|status:||Fix Committed → Fix Released|