]> git.ipfire.org Git - thirdparty/gcc.git/commit - gcc/c-family/ChangeLog
re PR c/66516 (missing diagnostic on taking the address of a builtin function)
authorMartin Sebor <msebor@redhat.com>
Thu, 3 Sep 2015 16:23:11 +0000 (16:23 +0000)
committerMartin Sebor <msebor@gcc.gnu.org>
Thu, 3 Sep 2015 16:23:11 +0000 (10:23 -0600)
commit1807ffc1a51df83a3ad26ad1b56ef0bbe8a7e494
treeb48648309af44524f8927ac7e65ea6eb947a7d9e
parent97875f4a942078f65739718c129b0b6289c4b43b
re PR c/66516 (missing diagnostic on taking the address of a builtin function)

gcc/ChangeLog
2015-09-03  Martin Sebor  <msebor@redhat.com>

PR c/66516
* doc/extend.texi (Other Builtins): Document when the address
of a built-in function can be taken.

gcc/c-family/ChangeLog
2015-09-03  Martin Sebor  <msebor@redhat.com>

PR c/66516
* c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
functions.
* c-common.c (reject_gcc_builtin): Define.

gcc/c/ChangeLog
2015-09-03  Martin Sebor  <msebor@redhat.com>

PR c/66516
* c/c-typeck.c (convert_arguments, parser_build_unary_op)
(build_conditional_expr, c_cast_expr, convert_for_assignment)
(build_binary_op, _objc_common_truthvalue_conversion): Call
reject_gcc_builtin.
(c_decl_implicit): Define.

gcc/cp/ChangeLog
2015-09-03  Martin Sebor  <msebor@redhat.com>

PR c/66516
* cp/cp-tree.h (mark_rvalue_use, decay_conversion): Add new
argument(s).
* cp/expr.c (mark_rvalue_use): Use new argument.
* cp/call.c (build_addr_func): Call decay_conversion with new
argument.
* cp/pt.c (convert_template_argument): Call reject_gcc_builtin.
* cp/typeck.c (decay_conversion): Use new argument.
(c_decl_implicit): Define.

gcc/testsuite/ChangeLog
2015-09-03  Martin Sebor  <msebor@redhat.com>

PR c/66516
* g++.dg/addr_builtin-1.C: New test.
* gcc.dg/addr_builtin-1.c: New test.

From-SVN: r227458
15 files changed:
gcc/ChangeLog
gcc/builtins.c.orig [new file with mode: 0644]
gcc/c-family/ChangeLog
gcc/c-family/c-common.c
gcc/c-family/c-common.h
gcc/c/ChangeLog
gcc/c/c-typeck.c
gcc/cp/ChangeLog
gcc/cp/call.c
gcc/cp/cp-tree.h
gcc/cp/expr.c
gcc/cp/pt.c
gcc/cp/typeck.c
gcc/doc/extend.texi
gcc/testsuite/ChangeLog