diff --git a/src/compiler/build_tables/build_parse_table.cc b/src/compiler/build_tables/build_parse_table.cc index c8f8a06b..6187f377 100644 --- a/src/compiler/build_tables/build_parse_table.cc +++ b/src/compiler/build_tables/build_parse_table.cc @@ -13,8 +13,6 @@ #include "compiler/build_tables/item_set_transitions.h" #include "compiler/build_tables/first_set.h" -#include - namespace tree_sitter { using std::pair; using std::string; @@ -99,8 +97,7 @@ namespace tree_sitter { auto current_action = current_actions.find(symbol); return ( current_action == current_actions.end() || - conflict_manager.resolve_parse_action(symbol, current_action->second, action) - ); + conflict_manager.resolve_parse_action(symbol, current_action->second, action)); } set precedence_values_for_item_set(const ParseItemSet &item_set) { diff --git a/src/compiler/build_tables/merge_transitions.h b/src/compiler/build_tables/merge_transitions.h index 52ab8d15..ccc0362e 100644 --- a/src/compiler/build_tables/merge_transitions.h +++ b/src/compiler/build_tables/merge_transitions.h @@ -2,6 +2,7 @@ #define COMPILER_BUILD_TABLES_MERGE_TRANSITIONS_H_ #include +#include #include "compiler/rules/character_set.h" #include "compiler/rules/symbol.h" diff --git a/src/compiler/generate_code/c_code.cc b/src/compiler/generate_code/c_code.cc index c086ec4b..d2dede17 100644 --- a/src/compiler/generate_code/c_code.cc +++ b/src/compiler/generate_code/c_code.cc @@ -293,7 +293,7 @@ namespace tree_sitter { case ParseActionTypeReduceExtra: add("REDUCE_EXTRA(" + symbol_id(action.symbol) + ")"); break; - default:; + default: {} } } @@ -309,7 +309,7 @@ namespace tree_sitter { case LexActionTypeError: line("LEX_ERROR();"); break; - default:; + default: {} } } diff --git a/src/compiler/prepare_grammar/prepare_grammar.cc b/src/compiler/prepare_grammar/prepare_grammar.cc index 12a42a33..42a39560 100644 --- a/src/compiler/prepare_grammar/prepare_grammar.cc +++ b/src/compiler/prepare_grammar/prepare_grammar.cc @@ -1,10 +1,9 @@ -#include "compiler/prepare_grammar/prepare_grammar.h" -#include "compiler/prepared_grammar.h" -#include "compiler/prepare_grammar/extract_tokens.h" #include "compiler/prepare_grammar/expand_repeats.h" #include "compiler/prepare_grammar/expand_tokens.h" +#include "compiler/prepare_grammar/extract_tokens.h" #include "compiler/prepare_grammar/intern_symbols.h" #include "compiler/prepare_grammar/interned_grammar.h" +#include "compiler/prepare_grammar/prepare_grammar.h" #include "compiler/prepared_grammar.h" namespace tree_sitter {