aboutsummaryrefslogtreecommitdiff
path: root/gdb/c-lang.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2020-03-13 17:39:52 -0600
committerTom Tromey <tom@tromey.com>2020-03-13 18:03:40 -0600
commit621821900289e9ef3472dc430d6fcf4d55b301e2 (patch)
tree499628efdf03d1e3787edfa9a294a929694281ce /gdb/c-lang.c
parent1e592a8ae0985645e61f6ffbfee064af8826b457 (diff)
downloadgdb-621821900289e9ef3472dc430d6fcf4d55b301e2.zip
gdb-621821900289e9ef3472dc430d6fcf4d55b301e2.tar.gz
gdb-621821900289e9ef3472dc430d6fcf4d55b301e2.tar.bz2
Introduce c_value_print_inner
This introduces c_value_print_inner, which implements the la_value_print_inner method for the C family of languages. In this patch, it is just a simple wrapper of c_val_print. However, subsequent patches will convert it to use the value API. The transformation is done this way to make each patch easier to review. Future patches will apply this same treatment to other languages as well. gdb/ChangeLog 2020-03-13 Tom Tromey <tom@tromey.com> * opencl-lang.c (opencl_language_defn): Use c_value_print_inner. * objc-lang.c (objc_language_defn): Use c_value_print_inner. * c-valprint.c (c_value_print_inner): New function. * c-lang.h (c_value_print_inner): Declare. * c-lang.c (c_language_defn, cplus_language_defn) (asm_language_defn, minimal_language_defn): Use c_value_print_inner.
Diffstat (limited to 'gdb/c-lang.c')
-rw-r--r--gdb/c-lang.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/c-lang.c b/gdb/c-lang.c
index 3526674..c919f02 100644
--- a/gdb/c-lang.c
+++ b/gdb/c-lang.c
@@ -904,7 +904,7 @@ extern const struct language_defn c_language_defn =
c_print_type, /* Print a type using appropriate syntax */
c_print_typedef, /* Print a typedef using appropriate syntax */
c_val_print, /* Print a value using appropriate syntax */
- nullptr, /* la_value_print_inner */
+ c_value_print_inner, /* la_value_print_inner */
c_value_print, /* Print a top-level value */
default_read_var_value, /* la_read_var_value */
NULL, /* Language specific skip_trampoline */
@@ -1050,7 +1050,7 @@ extern const struct language_defn cplus_language_defn =
c_print_type, /* Print a type using appropriate syntax */
c_print_typedef, /* Print a typedef using appropriate syntax */
c_val_print, /* Print a value using appropriate syntax */
- nullptr, /* la_value_print_inner */
+ c_value_print_inner, /* la_value_print_inner */
c_value_print, /* Print a top-level value */
default_read_var_value, /* la_read_var_value */
cplus_skip_trampoline, /* Language specific skip_trampoline */
@@ -1105,7 +1105,7 @@ extern const struct language_defn asm_language_defn =
c_print_type, /* Print a type using appropriate syntax */
c_print_typedef, /* Print a typedef using appropriate syntax */
c_val_print, /* Print a value using appropriate syntax */
- nullptr, /* la_value_print_inner */
+ c_value_print_inner, /* la_value_print_inner */
c_value_print, /* Print a top-level value */
default_read_var_value, /* la_read_var_value */
NULL, /* Language specific skip_trampoline */
@@ -1160,7 +1160,7 @@ extern const struct language_defn minimal_language_defn =
c_print_type, /* Print a type using appropriate syntax */
c_print_typedef, /* Print a typedef using appropriate syntax */
c_val_print, /* Print a value using appropriate syntax */
- nullptr, /* la_value_print_inner */
+ c_value_print_inner, /* la_value_print_inner */
c_value_print, /* Print a top-level value */
default_read_var_value, /* la_read_var_value */
NULL, /* Language specific skip_trampoline */