This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
What about merge function gen_trace_for_expr and function gen_eval_for_expr together?
- From: Hui Zhu <hui_zhu at mentor dot com>
- To: "gdb at sourceware dot org" <gdb at sourceware dot org>
- Date: Tue, 12 Jun 2012 08:15:57 +0800
- Subject: What about merge function gen_trace_for_expr and function gen_eval_for_expr together?
Hi guys,
When I read the code, I found that most part of these functions are same:
2c2
< gen_trace_for_expr (CORE_ADDR scope, struct expression *expr)
---
gen_eval_for_expr (CORE_ADDR scope, struct expression *expr)
12c12
< trace_kludge = 1;
---
trace_kludge = 0;
16,17c16
< /* Make sure we record the final object, and get rid of it. */
< gen_traced_pop (expr->gdbarch, ax, &value);
---
require_rvalue (ax, &value);
What about add a new argument for example trace or eval and merge them together?
Thanks,
Hui