parser/lexical.c, #4/10, rename `cw' --> `wlist_tail'
This commit is contained in:
parent
4cabf8fa6c
commit
b7f3dbc0fe
|
|
@ -75,7 +75,7 @@ static int numeofs = 0;
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define append(word) \
|
#define append(word) \
|
||||||
wl_append_word(&wlist, &cw, word)
|
wl_append_word(&wlist, &wlist_tail, word)
|
||||||
|
|
||||||
|
|
||||||
#define newword \
|
#define newword \
|
||||||
|
|
@ -124,7 +124,7 @@ cp_lexer(char *string)
|
||||||
{
|
{
|
||||||
int c, d;
|
int c, d;
|
||||||
int i, j;
|
int i, j;
|
||||||
wordlist *wlist, *cw;
|
wordlist *wlist, *wlist_tail;
|
||||||
char buf[NEW_BSIZE_SP], linebuf[NEW_BSIZE_SP];
|
char buf[NEW_BSIZE_SP], linebuf[NEW_BSIZE_SP];
|
||||||
int paren;
|
int paren;
|
||||||
|
|
||||||
|
|
@ -137,11 +137,11 @@ cp_lexer(char *string)
|
||||||
prompt();
|
prompt();
|
||||||
}
|
}
|
||||||
|
|
||||||
wlist = cw = NULL;
|
wlist = wlist_tail = NULL;
|
||||||
nloop:
|
nloop:
|
||||||
if (wlist)
|
if (wlist)
|
||||||
wl_free(wlist);
|
wl_free(wlist);
|
||||||
wlist = cw = NULL;
|
wlist = wlist_tail = NULL;
|
||||||
i = 0;
|
i = 0;
|
||||||
j = 0;
|
j = 0;
|
||||||
paren = 0;
|
paren = 0;
|
||||||
|
|
@ -218,7 +218,7 @@ nloop:
|
||||||
buf[i] = '\0';
|
buf[i] = '\0';
|
||||||
newword;
|
newword;
|
||||||
}
|
}
|
||||||
if (!cw)
|
if (!wlist_tail)
|
||||||
append(NULL);
|
append(NULL);
|
||||||
goto done;
|
goto done;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue