From 57f669dfda3d9328221f63f321b0d63c467cdaa0 Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Wed, 22 Jun 2016 14:11:08 -0700 Subject: [PATCH] clang-format --- src/runtime/language.c | 5 +++-- src/runtime/language.h | 5 ++--- src/runtime/parser.c | 6 ++++-- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/runtime/language.c b/src/runtime/language.c index b1360f8c..b117945b 100644 --- a/src/runtime/language.c +++ b/src/runtime/language.c @@ -12,8 +12,9 @@ void ts_language_table_entry(const TSLanguage *self, TSStateId state, result->action_count = 1; result->is_reusable = false; result->depends_on_lookahead = false; - result->actions = (symbol == ts_builtin_sym_error) ? &ERROR_SHIFT_EXTRA - : &self->recovery_actions[symbol]; + result->actions = (symbol == ts_builtin_sym_error) + ? &ERROR_SHIFT_EXTRA + : &self->recovery_actions[symbol]; return; } diff --git a/src/runtime/language.h b/src/runtime/language.h index 8a7eb1ea..8485143d 100644 --- a/src/runtime/language.h +++ b/src/runtime/language.h @@ -30,9 +30,8 @@ static inline const TSParseAction *ts_language_actions(const TSLanguage *self, return entry.actions; } -static inline const TSParseAction *ts_language_last_action(const TSLanguage *self, - TSStateId state, - TSSymbol symbol) { +static inline const TSParseAction *ts_language_last_action( + const TSLanguage *self, TSStateId state, TSSymbol symbol) { TableEntry entry; ts_language_table_entry(self, state, symbol, &entry); if (entry.action_count) diff --git a/src/runtime/parser.c b/src/runtime/parser.c index 9a38b0a5..685ca6a8 100644 --- a/src/runtime/parser.c +++ b/src/runtime/parser.c @@ -493,7 +493,8 @@ static Reduction ts_parser__reduce(TSParser *self, StackVersion version, parent->extra = true; new_state = state; } else { - const TSParseAction *action = ts_language_last_action(language, state, symbol); + const TSParseAction *action = + ts_language_last_action(language, state, symbol); assert(action); assert(action->type == TSParseActionTypeShift || action->type == TSParseActionTypeRecover); @@ -605,7 +606,8 @@ static StackIterateAction ts_parser__error_repair_callback( const TSParseAction *repair_symbol_action = ts_language_last_action(self->language, state, repair->symbol); - if (!repair_symbol_action || repair_symbol_action->type != TSParseActionTypeShift) + if (!repair_symbol_action || + repair_symbol_action->type != TSParseActionTypeShift) continue; TSStateId state_after_repair = repair_symbol_action->to_state;