comparison src/fns.c @ 20712:50255c536f0f

(mapcar1): Keep `i' in `i_before' before `i' is incremented by FETCH_STRING_CHAR_ADVANCE.
author Kenichi Handa <handa@m17n.org>
date Thu, 22 Jan 1998 01:26:45 +0000
parents d43ba5d91281
children 219fdecc30d3
comparison
equal deleted inserted replaced
20711:9ab8e061c0bf 20712:50255c536f0f
1993 int i_byte; 1993 int i_byte;
1994 1994
1995 for (i = 0, i_byte = 0; i < leni;) 1995 for (i = 0, i_byte = 0; i < leni;)
1996 { 1996 {
1997 int c; 1997 int c;
1998 FETCH_STRING_CHAR_ADVANCE (c, seq, i, i_byte) 1998 int i_before = i;
1999
2000 FETCH_STRING_CHAR_ADVANCE (c, seq, i, i_byte);
1999 XSETFASTINT (dummy, c); 2001 XSETFASTINT (dummy, c);
2000 vals[i] = call1 (fn, dummy); 2002 vals[i_before] = call1 (fn, dummy);
2001 } 2003 }
2002 } 2004 }
2003 else /* Must be a list, since Flength did not get an error */ 2005 else /* Must be a list, since Flength did not get an error */
2004 { 2006 {
2005 tail = seq; 2007 tail = seq;