Avoid missing field initializer warnings w/o default field syntax

The default field syntax aint working on windows
This commit is contained in:
Max Brunsfeld 2018-06-14 11:12:04 -07:00
parent 587d1a740a
commit 6e72c2943d
6 changed files with 67 additions and 85 deletions

View file

@ -17,7 +17,7 @@ struct InitialSyntaxGrammar {
std::set<std::set<rules::Symbol>> expected_conflicts;
std::vector<ExternalToken> external_tokens;
std::set<rules::Symbol> variables_to_inline;
rules::Symbol word_rule = rules::NONE();
rules::Symbol word_rule;
};
} // namespace prepare_grammar

View file

@ -60,7 +60,7 @@ struct SyntaxGrammar {
std::set<std::set<rules::Symbol>> expected_conflicts;
std::vector<ExternalToken> external_tokens;
std::set<rules::Symbol> variables_to_inline;
rules::Symbol word_rule = rules::NONE();
rules::Symbol word_rule;
};
} // namespace tree_sitter

View file

@ -28,11 +28,11 @@ static inline TSNode ts_node__null() {
// TSNode - accessors
uint32_t ts_node_start_byte(const TSNode self) {
uint32_t ts_node_start_byte(TSNode self) {
return self.context[0];
}
TSPoint ts_node_start_point(const TSNode self) {
TSPoint ts_node_start_point(TSNode self) {
return (TSPoint) {self.context[1], self.context[2]};
}