Clean up handling of incomplete line locations. (#3011)

Building on #3010, the handling of incomplete lines seems like it can be
straightened out. Doing this separately because it seemed better to
demonstrate tests aren't affected by the change.
This commit is contained in:
Jon Ross-Perkins authored and GitHub committed 2023-07-24 23:17:58 +00:00
1 parent a3d52b089d
commit a7c2885728
5 files changed
+51 -49

No files matched your search

+1 -2
View File
@@ -20,8 +20,7 @@ namespace Carbon {
auto ParseTree::Parse(TokenizedBuffer& tokens, DiagnosticConsumer& consumer,
llvm::raw_ostream* vlog_stream) -> ParseTree {
TokenizedBuffer::TokenLocationTranslator translator(
&tokens, /*last_line_lexed_to_column=*/nullptr);
TokenizedBuffer::TokenLocationTranslator translator(&tokens);
TokenDiagnosticEmitter emitter(translator, consumer);
// Delegate to the parser.