word def name state will handle all whitespaces anyways so simplified state change to it
This commit is contained in:
parent
4889472dd3
commit
2b2cc47d7a
17
engine/slc.h
17
engine/slc.h
@ -351,19 +351,18 @@ static inline slc_state slc_def_name_statechange(
|
|||||||
} else {
|
} else {
|
||||||
*prefix_i = -1;
|
*prefix_i = -1;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if(c == ':') {
|
||||||
|
*prefix_i = 0; /* XXX: restarts scan */
|
||||||
|
return SLC_WORD_NAME;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return current_state;
|
return current_state;
|
||||||
} else {
|
} else {
|
||||||
/* Check if ended by ':' after full prefix or not */
|
/* Not Found: Probably a word occurence */
|
||||||
if(prevc == ':' && (*prefix_i > 0) && prefix[*prefix_i] == 0) {
|
*prefix_i = 0; /* XXX: restarts scan */
|
||||||
/* Found: a word definition! */
|
return current_state;
|
||||||
return SLC_WORD_NAME;
|
|
||||||
} else {
|
|
||||||
/* Not Found: Probably a word occurence */
|
|
||||||
*prefix_i = 0; /* XXX: restarts scan */
|
|
||||||
return current_state;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user