On 02/19/2018 12:11 PM, Jakub Jelinek wrote:
> Hi!
>
> Many years ago Jason has added call to get_callee_fndecl, which does the
> right thing for internal functions as well as handles ADDR_EXPR and also
> casts and constant function pointers with a usable DECL_INITIAL, so while
> to fix this PR I could have added || CALL_EXPR_FN (t)) == NULL_TREE before
> the || TREE_CODE (CALL_EXPR_FN (t)) != ADDR_EXPR check, IMHO it is just
> better to remove it, get_callee_fndecl will DTRT.
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
>
> 2018-02-19 Jakub Jelinek <ja...@redhat.com>
>
> PR c++/84444
> * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
> is ADDR_EXPR.
>
> * g++.dg/cpp1z/launder8.C: New test.
OK.
jeff