Mercurial > emacs
comparison src/fns.c @ 26256:144cf26f35e1
(Flength): Unroll loop over lists.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Sun, 31 Oct 1999 02:01:59 +0000 |
parents | d44efc0b3243 |
children | f908261703d3 |
comparison
equal
deleted
inserted
replaced
26255:4ebced8747b7 | 26256:144cf26f35e1 |
---|---|
146 XSETFASTINT (val, XBOOL_VECTOR (sequence)->size); | 146 XSETFASTINT (val, XBOOL_VECTOR (sequence)->size); |
147 else if (COMPILEDP (sequence)) | 147 else if (COMPILEDP (sequence)) |
148 XSETFASTINT (val, XVECTOR (sequence)->size & PSEUDOVECTOR_SIZE_MASK); | 148 XSETFASTINT (val, XVECTOR (sequence)->size & PSEUDOVECTOR_SIZE_MASK); |
149 else if (CONSP (sequence)) | 149 else if (CONSP (sequence)) |
150 { | 150 { |
151 for (i = 0; CONSP (sequence); ++i) | 151 i = 0; |
152 { | 152 while (CONSP (sequence)) |
153 if ((i & 0xff) == 0) | 153 { |
154 QUIT; | |
155 sequence = XCDR (sequence); | 154 sequence = XCDR (sequence); |
155 ++i; | |
156 | |
157 if (!CONSP (sequence)) | |
158 break; | |
159 | |
160 sequence = XCDR (sequence); | |
161 ++i; | |
162 QUIT; | |
156 } | 163 } |
157 | 164 |
158 if (!NILP (sequence)) | 165 if (!NILP (sequence)) |
159 wrong_type_argument (Qlistp, sequence); | 166 wrong_type_argument (Qlistp, sequence); |
160 | 167 |