aboutsummaryrefslogtreecommitdiff
path: root/gdb/minsyms.h
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-03-01 17:37:30 -0700
committerTom Tromey <tom@tromey.com>2019-03-15 16:02:07 -0600
commit3db066bcd5bac9a8d6be85ea4cfa8f52dbdcc600 (patch)
treef02e90d1b855a0277be4e00d47a0bc615bcf3b0c /gdb/minsyms.h
parent2219ae0b0ebe14373850b000c2abaa31dab1d741 (diff)
downloadgdb-3db066bcd5bac9a8d6be85ea4cfa8f52dbdcc600.zip
gdb-3db066bcd5bac9a8d6be85ea4cfa8f52dbdcc600.tar.gz
gdb-3db066bcd5bac9a8d6be85ea4cfa8f52dbdcc600.tar.bz2
Slightly simplify minsym creation
Only one caller of minimal_symbol_reader::record_with_info was using the return value, so this patch simplifies this code by having it return void and changing that caller to use record_full instead. gdb/ChangeLog 2019-03-15 Tom Tromey <tom@tromey.com> * minsyms.h (class minimal_symbol_reader) <record_with_info>: Don't return the symbol. * coffread.c (record_minimal_symbol): Use record_full.
Diffstat (limited to 'gdb/minsyms.h')
-rw-r--r--gdb/minsyms.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/gdb/minsyms.h b/gdb/minsyms.h
index 729d394..532436c 100644
--- a/gdb/minsyms.h
+++ b/gdb/minsyms.h
@@ -116,14 +116,15 @@ class minimal_symbol_reader
/* Like record_full, but:
- uses strlen to compute NAME_LEN,
- - passes COPY_NAME = true. */
+ - passes COPY_NAME = true.
- struct minimal_symbol *record_with_info (const char *name,
- CORE_ADDR address,
- enum minimal_symbol_type ms_type,
- int section)
+ This variant does not return the new symbol. */
+
+ void record_with_info (const char *name, CORE_ADDR address,
+ enum minimal_symbol_type ms_type,
+ int section)
{
- return record_full (name, strlen (name), true, address, ms_type, section);
+ record_full (name, strlen (name), true, address, ms_type, section);
}
private: