OSDN Git Service

2008-04-24 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 24 Apr 2008 16:18:46 +0000 (16:18 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 24 Apr 2008 16:18:46 +0000 (16:18 +0000)
commitd43cee800138618010046d2743fb00eb37c8c429
tree35dd8b11788bce7a6dab65c4d291872b84068f45
parent5791999fefcf73fcef43d5b590dee1113be5c3af
2008-04-24  Richard Guenther  <rguenther@suse.de>

* c-common.h (check_builtin_function_arguments): Declare.
* c-common.c (validate_nargs): New function.
(check_builtin_function_arguments): Likewise.
* c-typeck.c (build_function_call): Call
check_builtin_function_arguments.
* builtins.c (fold_builtin_classify): Remove error reporting code.
(fold_builtin_unordered_cmp): Likewise.
(fold_builtin_1): Likewise.
(fold_builtin_n): Likewise.

cp/
* typeck.c (cp_build_function_call): Call
check_builtin_function_arguments.

* gcc.dg/builtin-constant_p-1.c: New testcase.
* gcc.dg/builtin-errors.c: Adjust expected error.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@134635 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/builtins.c
gcc/c-common.c
gcc/c-common.h
gcc/c-typeck.c
gcc/cp/ChangeLog
gcc/cp/typeck.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/builtin-constant_p-1.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/builtins-error.c