Remove preceding_escaped_nl

It's no longer necessary for fish_indent
This commit is contained in:
ridiculousfish
2020-07-07 13:48:35 -07:00
parent 8d25ed962c
commit 72e35af381
4 changed files with 0 additions and 24 deletions

View File

@@ -498,12 +498,10 @@ maybe_t<tok_t> tokenizer_t::next() {
// Consume non-newline whitespace. If we get an escaped newline, mark it and continue past
// it.
bool preceding_escaped_nl = false;
for (;;) {
if (this->token_cursor[0] == L'\\' && this->token_cursor[1] == L'\n') {
this->token_cursor += 2;
this->continue_line_after_comment = true;
preceding_escaped_nl = true;
} else if (iswspace_not_nl(this->token_cursor[0])) {
this->token_cursor++;
} else {
@@ -527,7 +525,6 @@ maybe_t<tok_t> tokenizer_t::next() {
tok_t result(token_type_t::comment);
result.offset = comment_start - this->start;
result.length = comment_len;
result.preceding_escaped_nl = preceding_escaped_nl;
return result;
}
while (iswspace_not_nl(this->token_cursor[0])) this->token_cursor++;
@@ -651,7 +648,6 @@ maybe_t<tok_t> tokenizer_t::next() {
}
}
assert(result.has_value() && "Should have a token");
result->preceding_escaped_nl = preceding_escaped_nl;
return result;
}