aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2025-02-24 15:36:28 -0700
committerTom Tromey <tom@tromey.com>2025-03-11 08:33:08 -0600
commitd8a30dd2a692053165ff3dfad1e93164180fc974 (patch)
tree6394ee19ffc03420892e09ede7ad51dda17bcef1
parentd9c531fd6478ccfcb7fd5baf0dad54549508db9f (diff)
downloadbinutils-d8a30dd2a692053165ff3dfad1e93164180fc974.zip
binutils-d8a30dd2a692053165ff3dfad1e93164180fc974.tar.gz
binutils-d8a30dd2a692053165ff3dfad1e93164180fc974.tar.bz2
Use gdb set and map in TUI
This changes the TUI to use gdb::unordered_map and gdb::unordered_set rather than the std:: variants. Approved-By: Simon Marchi <simon.marchi@efficios.com>
-rw-r--r--gdb/tui/tui-layout.c4
-rw-r--r--gdb/tui/tui-layout.h5
2 files changed, 4 insertions, 5 deletions
diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c
index 79b7289..3fac65f 100644
--- a/gdb/tui/tui-layout.c
+++ b/gdb/tui/tui-layout.c
@@ -24,7 +24,7 @@
#include "frame.h"
#include "cli/cli-decode.h"
#include "cli/cli-utils.h"
-#include <unordered_set>
+#include "gdbsupport/unordered_set.h"
#include "tui/tui.h"
#include "tui/tui-command.h"
@@ -1221,7 +1221,7 @@ tui_new_layout_command (const char *spec, int from_tty)
std::vector<std::unique_ptr<tui_layout_split>> splits;
splits.emplace_back (new tui_layout_split (is_vertical));
- std::unordered_set<std::string> seen_windows;
+ gdb::unordered_set<std::string> seen_windows;
while (true)
{
spec = skip_spaces (spec);
diff --git a/gdb/tui/tui-layout.h b/gdb/tui/tui-layout.h
index 22d7c72..107b123 100644
--- a/gdb/tui/tui-layout.h
+++ b/gdb/tui/tui-layout.h
@@ -27,8 +27,7 @@
#include "tui/tui.h"
#include "tui/tui-data.h"
#include "gdbsupport/iterator-range.h"
-
-#include <unordered_map>
+#include "gdbsupport/unordered_map.h"
/* Values that can be returned when handling a request to adjust a
window's size. */
@@ -368,7 +367,7 @@ typedef std::function<tui_win_info * (const char *name)> window_factory;
/* The type for a data structure that maps a window name to that window's
factory function. */
-typedef std::unordered_map<std::string, window_factory> window_types_map;
+typedef gdb::unordered_map<std::string, window_factory> window_types_map;
/* Register a new TUI window type. NAME is the name of the window
type. FACTORY is a function that can be called to instantiate the