aboutsummaryrefslogtreecommitdiff
path: root/gdb/ada-lang.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2021-06-25 21:35:40 -0400
committerSimon Marchi <simon.marchi@polymtl.ca>2021-06-25 21:35:40 -0400
commit0f8e2034128e4a73e02cb8311eeeea7e886a5985 (patch)
tree609b9baf7a5f167daa28b0341743aa650677f28a /gdb/ada-lang.c
parentac2d77c6a102ca785aae565aec93a3478a9f4544 (diff)
downloadgdb-0f8e2034128e4a73e02cb8311eeeea7e886a5985.zip
gdb-0f8e2034128e4a73e02cb8311eeeea7e886a5985.tar.gz
gdb-0f8e2034128e4a73e02cb8311eeeea7e886a5985.tar.bz2
gdb: add context getter/setter to cmd_list_element
Straightforward replacement of get_cmd_context / set_cmd_context with cmd_list_element methods. gdb/ChangeLog: * cli/cli-decode.h (struct cmd_list_element) <set_context, context>: New. <context>: Rename to... <m_context>: ... this. * cli/cli-decode.c (set_cmd_context, get_cmd_context): Remove. * command.h (set_cmd_context, get_cmd_context): Remove, use cmd_list_element::set_context and cmd_list_element::context everywhere instead. Change-Id: I5016b0079014e3f17d1aa449ada7954473bf2b5d
Diffstat (limited to 'gdb/ada-lang.c')
-rw-r--r--gdb/ada-lang.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index f2270c0..b098991 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -49,6 +49,7 @@
#include "typeprint.h"
#include "namespace.h"
#include "cli/cli-style.h"
+#include "cli/cli-decode.h"
#include "value.h"
#include "mi/mi-common.h"
@@ -12229,7 +12230,7 @@ catch_ada_exception_command (const char *arg_entry, int from_tty,
std::string excep_string;
std::string cond_string;
- tempflag = get_cmd_context (command) == CATCH_TEMPORARY;
+ tempflag = command->context () == CATCH_TEMPORARY;
if (!arg)
arg = "";
@@ -12254,7 +12255,7 @@ catch_ada_handlers_command (const char *arg_entry, int from_tty,
std::string excep_string;
std::string cond_string;
- tempflag = get_cmd_context (command) == CATCH_TEMPORARY;
+ tempflag = command->context () == CATCH_TEMPORARY;
if (!arg)
arg = "";
@@ -12322,7 +12323,7 @@ catch_assert_command (const char *arg_entry, int from_tty,
int tempflag;
std::string cond_string;
- tempflag = get_cmd_context (command) == CATCH_TEMPORARY;
+ tempflag = command->context () == CATCH_TEMPORARY;
if (!arg)
arg = "";