diff --git a/common/scanner.h b/common/scanner.h index 02d77a95..06e7a7a4 100644 --- a/common/scanner.h +++ b/common/scanner.h @@ -473,8 +473,7 @@ static bool scan(Scanner *scanner, TSLexer *lexer, const bool *valid_symbols) { array_delete(&word); lexer->mark_end(lexer); - String last_word = array_pop(&scanner->heredocs).word; - array_delete(&last_word); + array_delete(&array_pop(&scanner->heredocs).word); return true; }