forked from Imagelibrary/binutils-gdb
Use reference result of emplace_back
Starting with C++17, emplace_back returns a reference to the new object. This patch changes code that uses emplace_back followed by a call to back() to simply use this reference instead. Approved-By: Simon Marchi <simon.marchi@efficios.com>
This commit is contained in:
@@ -4027,8 +4027,7 @@ start_thread (struct gdb_xml_parser *parser,
|
||||
char *id = (char *) xml_find_attribute (attributes, "id")->value.get ();
|
||||
ptid_t ptid = read_ptid (id, NULL);
|
||||
|
||||
data->items.emplace_back (ptid);
|
||||
thread_item &item = data->items.back ();
|
||||
thread_item &item = data->items.emplace_back (ptid);
|
||||
|
||||
attr = xml_find_attribute (attributes, "core");
|
||||
if (attr != NULL)
|
||||
|
||||
Reference in New Issue
Block a user