Return unique_ptr from language_defn::get_compile_context
authorTom Tromey <tom@tromey.com>
Fri, 5 Feb 2021 14:17:11 +0000 (07:17 -0700)
committerTom Tromey <tom@tromey.com>
Fri, 5 Feb 2021 14:17:12 +0000 (07:17 -0700)
commitbdfea17ea9bbd9f92ad19a70d770af42473d9c07
treecd14e3cb96c9123721ac6416a4b94d7682c65c93
parent1b30f42106cfd50ef1c020db2ca31f2fbe51ef8a
Return unique_ptr from language_defn::get_compile_context

This changes language_defn::get_compile_context to return a
unique_ptr.  This makes the ownership transfer clear.

gdb/ChangeLog
2021-02-05  Tom Tromey  <tom@tromey.com>

* compile/compile-c-support.c (get_compile_context)
(c_get_compile_context, cplus_get_compile_context): Change return
type.
* language.c (language_defn::get_compile_instance): New method.
* language.h (language_defn::get_compile_instance): Change return
type.  No longer inline.
* c-lang.c (c_language::get_compile_instance): Change return type.
(cplus_language::get_compile_instance): Change return type.
* c-lang.h (c_get_compile_context, cplus_get_compile_context):
Change return type.
* compile/compile.c (compile_to_object): Update.
gdb/ChangeLog
gdb/c-lang.c
gdb/c-lang.h
gdb/compile/compile-c-support.c
gdb/compile/compile.c
gdb/language.c
gdb/language.h
This page took 0.026076 seconds and 4 git commands to generate.