summaryrefslogtreecommitdiff
path: root/gdb/dwarf2/cooked-index.h
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2023-12-03 12:40:06 -0700
committerTom Tromey <tom@tromey.com>2024-01-18 08:20:17 -0700
commit36cde74bd8ba912604dd675bc5046c20fb8c5d68 (patch)
tree50f1e3295f5b99fd7e6b4bef797821d5b785757a /gdb/dwarf2/cooked-index.h
parent47efef8f2d8a10b63d2c6125aded1d2da69d8a04 (diff)
Remove cooked_index_worker::start_reading
I noticed that cooked_index_worker::start_reading isn't really needed. This patch removes it, and also removes the SCOPED_EXIT, in favor of a direct call.
Diffstat (limited to 'gdb/dwarf2/cooked-index.h')
-rw-r--r--gdb/dwarf2/cooked-index.h15
1 files changed, 5 insertions, 10 deletions
diff --git a/gdb/dwarf2/cooked-index.h b/gdb/dwarf2/cooked-index.h
index f063fe088e8..86fbb8ffac4 100644
--- a/gdb/dwarf2/cooked-index.h
+++ b/gdb/dwarf2/cooked-index.h
@@ -534,13 +534,8 @@ protected:
friend class cooked_index;
void set (cooked_state desired_state);
- /* Start reading DWARF. This can be run in a worker thread without
- problems. */
- void start_reading ();
-
- /* Helper function that does most of the work for start_reading.
- This must be able to be run in a worker thread without
- problems. */
+ /* Helper function that does the work of reading. This must be able
+ to be run in a worker thread without problems. */
virtual void do_reading () = 0;
/* A callback that can print stats, if needed. This is called when
@@ -579,9 +574,9 @@ protected:
arose during scanning have been reported by 'wait'. This may
only be modified on the main thread. */
bool m_reported = false;
- /* If set, an exception occurred during start_reading; in this case
- the scanning is stopped and this exception will later be reported
- by the 'wait' method. */
+ /* If set, an exception occurred during reading; in this case the
+ scanning is stopped and this exception will later be reported by
+ the 'wait' method. */
std::optional<gdb_exception> m_failed;
};