aboutsummaryrefslogtreecommitdiff
path: root/gdb/opencl-lang.c
diff options
context:
space:
mode:
authorAndrew Burgess <andrew.burgess@embecosm.com>2020-07-31 15:56:15 +0100
committerAndrew Burgess <andrew.burgess@embecosm.com>2020-09-16 11:04:03 +0100
commit1ac14a04025b105c1975ceb3b07245c811518bcb (patch)
treee2a8f0a6c9cd98757fe090be90d0ca32537954aa /gdb/opencl-lang.c
parent3a3440fb8b71a3a4ac919eb5a7edd69be7d5cfff (diff)
downloadgdb-1ac14a04025b105c1975ceb3b07245c811518bcb.zip
gdb-1ac14a04025b105c1975ceb3b07245c811518bcb.tar.gz
gdb-1ac14a04025b105c1975ceb3b07245c811518bcb.tar.bz2
gdb: Convert language_data::la_macro_expansion to a method
Convert language_data::la_macro_expansion member variable to a virtual method language_defn::macro_expansion. There should be no user visible changes after this commit. gdb/ChangeLog: * ada-lang.c (ada_language_data): Remove la_macro_expansion initializer. * c-lang.c (c_language_data): Likewise. (c_language::macro_expansion): New member function. (cplus_language_data): Likewise. (cplus_language::macro_expansion): New member function. (asm_language_data): Likewise. (asm_language::macro_expansion): New member function. (minimal_language_data): Likewise. (minimal_language::macro_expansion): New member function. * d-lang.c (d_language_data): Remove la_macro_expansion initializer. * f-lang.c (f_language_data): Likewise. * go-lang.c (go_language_data): Likewise. * language.c (unknown_language_data): Likewise. (auto_language_data): Likewise. * language.h (language_data): Remove la_macro_expansion field. (language_defn::macro_expansion): New member function. * m2-lang.c (m2_language_data): Remove la_macro_expansion initializer. * objc-lang.c (objc_language_data): Likewise. (objc_language::macro_expansion): New member function. * opencl-lang.c (opencl_language_data): Likewise. (opencl_language::macro_expansion): New member function. * p-lang.c (pascal_language_data): Remove la_macro_expansion initializer. * rust-lang.c (rust_language_data): Likewise. * symtab.c (default_collect_symbol_completion_matches_break_on): Update call to macro_expansion.
Diffstat (limited to 'gdb/opencl-lang.c')
-rw-r--r--gdb/opencl-lang.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gdb/opencl-lang.c b/gdb/opencl-lang.c
index dffdae4..8f19f25 100644
--- a/gdb/opencl-lang.c
+++ b/gdb/opencl-lang.c
@@ -1006,7 +1006,6 @@ const struct exp_descriptor exp_descriptor_opencl =
/* Constant data representing the OpenCL language. */
extern const struct language_data opencl_language_data =
{
- macro_expansion_c,
&exp_descriptor_opencl,
c_op_print_tab, /* expression operators for printing */
&default_varobj_ops,
@@ -1067,6 +1066,11 @@ public:
c_print_type (type, varstring, stream, show, level, flags);
}
+
+ /* See language.h. */
+
+ enum macro_expansion macro_expansion () const override
+ { return macro_expansion_c; }
};
/* Single instance of the OpenCL language class. */