This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 2/2] C++: show private field accessor hints with -g and optimization (PR c++/84994)
On Tue, Mar 20, 2018 at 7:37 PM, David Malcolm <dmalcolm@redhat.com> wrote:
> PR c++/84894 reports that the fix-it hints suggesting accessor calls for
> private fields doesn't work with -g for -O1 and above.
>
> The issue is that field_accessor_p requires DECL_SAVED_TREE (fn) to be
> a RETURN_EXPR, but the former is a STATEMENT_LIST, created in
> start_preparsed_function here:
Would constexpr_fn_retval be useful here?
Jason