aboutsummaryrefslogtreecommitdiff
path: root/gdb/eval.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2021-03-08 07:27:57 -0700
committerTom Tromey <tom@tromey.com>2021-03-08 07:28:19 -0700
commit373907ffb2db9232af14d2a7e4433f41cc1fc56c (patch)
treef81c492c40c56c246d27df0c07f743d2412e0c63 /gdb/eval.c
parent5133d78b7bf19f350865c9515839865503cacfa9 (diff)
downloadgdb-373907ffb2db9232af14d2a7e4433f41cc1fc56c.zip
gdb-373907ffb2db9232af14d2a7e4433f41cc1fc56c.tar.gz
gdb-373907ffb2db9232af14d2a7e4433f41cc1fc56c.tar.bz2
Introduce binop_operation
This adds two new template classes, binop_operation and usual_ax_binop_operation, and then uses these to implement a number of binary operations that follow similar patterns. gdb/ChangeLog 2021-03-08 Tom Tromey <tom@tromey.com> * expop.h (class binop_operation, class usual_ax_binop_operation): New. (exp_operation, intdiv_operation, mod_operation, mul_operation) (div_operation, rem_operation, lsh_operation, rsh_operation) (bitwise_and_operation, bitwise_ior_operation) (bitwise_xor_operation): New typedefs. * eval.c (eval_op_binary): No longer static.
Diffstat (limited to 'gdb/eval.c')
-rw-r--r--gdb/eval.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/eval.c b/gdb/eval.c
index 87c8b0d..6fde03d 100644
--- a/gdb/eval.c
+++ b/gdb/eval.c
@@ -1511,7 +1511,7 @@ eval_op_sub (struct type *expect_type, struct expression *exp,
/* Helper function for several different binary operations. */
-static struct value *
+struct value *
eval_op_binary (struct type *expect_type, struct expression *exp,
enum noside noside, enum exp_opcode op,
struct value *arg1, struct value *arg2)