gcc/c/ PR c/120055 * c-typeck.cc (convert_arguments): Check if fundecl is null before checking for builtin function declaration.
--- gcc/c/c-typeck.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/c/c-typeck.cc b/gcc/c/c-typeck.cc index c7a13bf2b2f..9fd568feee3 100644 --- a/gcc/c/c-typeck.cc +++ b/gcc/c/c-typeck.cc @@ -4337,7 +4337,7 @@ convert_arguments (location_t loc, vec<location_t> arg_loc, tree fntype, } if (!typetail && parmnum == 0 && !TYPE_NO_NAMED_ARGS_STDARG_P (fntype) - && !fndecl_built_in_p (fundecl)) + && fundecl && !fndecl_built_in_p (fundecl)) { auto_diagnostic_group d; bool warned; base-commit: fd013e3fe47f2623b581213c6d7c08bdbd5b1614