summaryrefslogtreecommitdiff
path: root/gcc/c
diff options
context:
space:
mode:
authorbernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>2016-01-13 20:03:26 +0000
committerbernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>2016-01-13 20:03:26 +0000
commitbda05c57770fdc3b48c608d01d3aa74b17382731 (patch)
treec35775b90eda0d70234de508315954e7ece5b4b0 /gcc/c
parent9b657cf1cae2d2db644ecba8e3e499e9ef16e6b1 (diff)
downloadgcc-bda05c57770fdc3b48c608d01d3aa74b17382731.tar.gz
Improve warning locations (PR66208)
PR c/66208 * c-common.c (check_function_nonnull): Remove unnecessary declaration. Add new arg loc and pass it down as context. (check_nonnull_arg): Don't mark ctx arg as unused. Use it as a pointer to the location to use for the warning. (check_function_arguments): New arg loc. All callers changed. Pass it to check_function_nonnull. * c-common.h (check_function_arguments): Adjust declaration. testsuite/ PR c/66208 * c-c++-common/pr66208.c: New file. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@232345 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c')
-rw-r--r--gcc/c/c-typeck.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/c/c-typeck.c b/gcc/c/c-typeck.c
index 952041b512b..d602e3383e9 100644
--- a/gcc/c/c-typeck.c
+++ b/gcc/c/c-typeck.c
@@ -3048,7 +3048,7 @@ build_function_call_vec (location_t loc, vec<location_t> arg_loc,
return error_mark_node;
/* Check that the arguments to the function are valid. */
- check_function_arguments (fntype, nargs, argarray);
+ check_function_arguments (loc, fntype, nargs, argarray);
if (name != NULL_TREE
&& !strncmp (IDENTIFIER_POINTER (name), "__builtin_", 10))