diff options
author | Tom Tromey <tom@tromey.com> | 2021-03-08 07:27:57 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2021-03-08 07:28:26 -0700 |
commit | fc715eb288a8f364616c7adc16afd8ba74849d62 (patch) | |
tree | a4fbc6640000e82c3e63d66ccb712480d9d1ef48 /gdb/ada-lang.c | |
parent | cc6bd32eeac6b31b036a172b6841d699e05b285f (diff) | |
download | binutils-fc715eb288a8f364616c7adc16afd8ba74849d62.zip binutils-fc715eb288a8f364616c7adc16afd8ba74849d62.tar.gz binutils-fc715eb288a8f364616c7adc16afd8ba74849d62.tar.bz2 |
Introduce ada_ternop_range_operation
This adds class ada_ternop_range_operation, which implements
TERNOP_IN_RANGE.
gdb/ChangeLog
2021-03-08 Tom Tromey <tom@tromey.com>
* ada-lang.c (ada_ternop_range_operation::evaluate): New method.
* ada-exp.h (class ada_ternop_range_operation): New.
Diffstat (limited to 'gdb/ada-lang.c')
-rw-r--r-- | gdb/ada-lang.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 409ffb9..dd88466 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -10436,6 +10436,17 @@ ada_qual_operation::evaluate (struct type *expect_type, return std::get<0> (m_storage)->evaluate (type, exp, noside); } +value * +ada_ternop_range_operation::evaluate (struct type *expect_type, + struct expression *exp, + enum noside noside) +{ + value *arg0 = std::get<0> (m_storage)->evaluate (nullptr, exp, noside); + value *arg1 = std::get<1> (m_storage)->evaluate (nullptr, exp, noside); + value *arg2 = std::get<2> (m_storage)->evaluate (nullptr, exp, noside); + return eval_ternop_in_range (expect_type, exp, noside, arg0, arg1, arg2); +} + } /* Implement the evaluate_exp routine in the exp_descriptor structure |