Re: [PATCH 9/9] C++ compile support

Eli Zaretskii
2018-08-11T07:22:11Z

> From: Keith Seitz <keiths@redhat.com>
> Date: Fri, 10 Aug 2018 16:25:34 -0700
>
> This initial support has several glaring omissions:
> - No template support at all
> I have follow-on patches for this, but they add much complexity
> to this "basic" support. Consequently, they will be submitted separately.
> - Cannot print functions
> The code template needs tweaking, and I simply haven't gotten to it yet.
> - So-called "special function" support is not included
> Using constructors, destructors, operators, etc will not work. I have
> follow-on patches for that, but they require some work because of the
> recent churn in symbol searching.
> - There are several test suite references to "compile/1234" bugs.
> I will file bugs and update the test suite's bug references before pushing
> these patches.

Shouldn't these omissions be mentioned somewhere? Like in NEWS?

> +* GDB now has experimental support for the compilation and injection of
> + C++ source code into the inferior. This feature requires the GCC C++
> + plug-in available since GCC 7.1.

The last sentence basically means "only on ELF platforms", right? So
IMO this limitation should be stated explicitly, lest people get
excited, and then get disappointed.

> +set debug compile-oracle
> +show debug compile-oracle
> + Control the display of debug output about symbol requests from
> + the compiler plug-in.
> +
> +set debug compile-cplus-types
> +show debug compile-cplus-types
> + Control the display of debug output about C++ type conversion
> + in the compile feature.

I suggest to mention that these commands are only available/have
effect if the C++ compilation is supported.

> +@anchor{set debug compile-oracle}
> +@item set debug compile-oracle
> +@cindex compile oracle debugging info
> +Turns on or off display of symbol requests from the compiler plug-in
> +(the ``oracle''). The default is off.

@dfn{oracle} should render better. In any case, why do we call this
"the oracle"? In the computing context, "oracle" has connotations
that we don't necessarily want to encourage, I think. Why not
something like "set debug symbol-requests"?

> +Turns on or off the display of C++ type conversion debugging information.

Please use C@t{++} for C++ in the text, it renders better in the
printed manual.

OK for the documentation parts, with those nits fixed.

Thanks.