Talk:c/language/function declaration

The current text has: "The return type of the function, determined by the type specifier in specifiers-and-qualifiers and possibly modified by the declarator as usual in declarations, must be a complete non-array object type or the type void."

I can't find any requirement in the standard that the return type has to be complete in a function declaration. Is this an error?

Declarations such as are accepted just fine by compilers. Of course you cannot call the function unless the type is completed, nor can you define it, but for instance you can still create pointers to it and pass them around. Example on godbolt.

See also this StackOverflow question.

--Nate Eldredge (talk) 22:32, 11 December 2020 (PST)
 * Fixed. --Fruderica (talk) 23:54, 11 December 2020 (PST)

possible mistake about scope
In this code sample:

should'nt it be block scope ?

Babbage (talk) 03:12, 6 October 2022 (PDT)


 * yes, I think you're right; edited as such --Cubbi (talk) 09:20, 6 October 2022 (PDT)