From fc91e2b3c68621a7315621f46445322835b2316a Mon Sep 17 00:00:00 2001 From: Owen Avery Date: Sun, 9 Jul 2023 20:46:03 -0400 Subject: gccrs: Remove Linemap::start_line gcc/rust/ChangeLog: * lex/rust-lex.cc (Lexer::start_line): Use linemap_line_start. * rust-linemap.cc (Linemap::start_line): Remove. * rust-linemap.h (Linemap::start_line): Remove. Signed-off-by: Owen Avery --- gcc/rust/lex/rust-lex.cc | 2 +- gcc/rust/rust-linemap.cc | 8 -------- gcc/rust/rust-linemap.h | 5 ----- 3 files changed, 1 insertion(+), 14 deletions(-) (limited to 'gcc/rust') diff --git a/gcc/rust/lex/rust-lex.cc b/gcc/rust/lex/rust-lex.cc index 6085a83..1e4a362 100644 --- a/gcc/rust/lex/rust-lex.cc +++ b/gcc/rust/lex/rust-lex.cc @@ -2523,7 +2523,7 @@ void Lexer::start_line (int current_line, int current_column) { if (line_map) - line_map->start_line (current_line, current_column); + linemap_line_start (line_table, current_line, current_column); } } // namespace Rust diff --git a/gcc/rust/rust-linemap.cc b/gcc/rust/rust-linemap.cc index 627f904..9abafd4 100644 --- a/gcc/rust/rust-linemap.cc +++ b/gcc/rust/rust-linemap.cc @@ -67,14 +67,6 @@ Linemap::stop () this->in_file_ = false; } -// Start a new line. - -void -Linemap::start_line (unsigned lineno, unsigned linesize) -{ - linemap_line_start (line_table, lineno, linesize); -} - // Return the Linemap to use for the gcc backend. Linemap * diff --git a/gcc/rust/rust-linemap.h b/gcc/rust/rust-linemap.h index 5ed8ecf..6d159e7 100644 --- a/gcc/rust/rust-linemap.h +++ b/gcc/rust/rust-linemap.h @@ -47,11 +47,6 @@ public: // 0, but it will be non-zero if the Rust source has a //line comment. void start_file (const char *file_name, unsigned int line_begin); - // Subsequent Location values will come from the line LINE_NUMBER, - // in the current file. LINE_SIZE is the size of the line in bytes. - // This will normally be called for every line in a source file. - void start_line (unsigned int line_number, unsigned int line_size); - // Stop generating Location values. This will be called after all // input files have been read, in case any cleanup is required. void stop (); -- cgit v1.1