[ ] should be processed by parser, not by scanner.

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@2136 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc
2008-03-10 14:11:38 +00:00
parent 93e6f17c3b
commit cab59d9f3a
3 changed files with 16 additions and 18 deletions

View File

@@ -1161,23 +1161,13 @@ Yap_tokenizer(int inp_stream)
case BK:
och = ch;
do {
ch = Nxtch(inp_stream);
} while (chtype(ch) == BS);
if (och == '[' && ch == ']') {
t->TokInfo = Unsigned(AtomNil);
ch = Nxtch(inp_stream);
t->Tok = Ord(kind = Name_tok);
if (ch == '(')
solo_flag = FALSE;
} else {
t->TokInfo = och;
if (t->TokInfo == '(' && !solo_flag) {
t->TokInfo = 'l';
solo_flag = TRUE;
}
t->Tok = Ord(kind = Ponctuation_tok);
ch = Nxtch(inp_stream);
t->TokInfo = och;
if (t->TokInfo == '(' && !solo_flag) {
t->TokInfo = 'l';
solo_flag = TRUE;
}
t->Tok = Ord(kind = Ponctuation_tok);
break;
case EF: