Closed LegionMammal978 closed 4 months ago
OK, I've finally gotten around to this and took a machete to the section. It was just too much anyway. But I think I have it right based on your much-appreciated feedback. Please reopen if there's still something wrong in there.
Cheers!
In 41.1.1, "
inline
for Speed—Maybe", you write:This is not quite accurate: a function definition with
extern inline
is no longer an inline definition (C17 6.7.4/7), so it behaves identically to a normalextern
definition (except for the suggestion to the compiler). So there's only ever one version of the definition.As it happens, using an non-static inline definition without providing an external definition is always forbidden in ISO C (C17 6.9/5, emphasis mine):
So such a program is always considered invalid, even though the compiler need not produce an error or warning.
Nor can you call any
static
functions from a non-static
inline definition.