Add parser error messages

This commit is contained in:
Max Brunsfeld 2014-01-08 18:35:16 -08:00
parent 614e497ac4
commit 55809f702d
14 changed files with 213 additions and 83 deletions

View file

@ -45,6 +45,14 @@ namespace tree_sitter {
}
}
// State
unordered_set<CharMatch> LexState::expected_inputs() const {
unordered_set<CharMatch> result;
for (auto pair : actions)
result.insert(pair.first);
return result;
}
// Table
size_t LexTable::add_state() {
states.push_back(LexState());