let's just use ((void *)-1) as another invalid pointer result

This commit is contained in:
Sven M. Hallberg 2015-09-05 22:43:49 +02:00
parent 90b6f30fa1
commit 8995097a1d
3 changed files with 5 additions and 6 deletions

View file

@ -349,7 +349,7 @@ void *h_stringmap_get(const HStringMap *m, const uint8_t *str, size_t n, bool en
return m->epsilon_branch;
}
// A NULL result means no parse. H_NEED_INPUT means lookahead is too short.
// A NULL result means no parse. NEED_INPUT means lookahead is too short.
void *h_stringmap_get_lookahead(const HStringMap *m, HInputStream lookahead)
{
while(m) {
@ -368,7 +368,7 @@ void *h_stringmap_get_lookahead(const HStringMap *m, HInputStream lookahead)
// XXX assumption of byte-wise grammar and input
return m->end_branch;
} else {
return H_NEED_INPUT;
return NEED_INPUT;
}
}