Consider the following example (in the same translation unit):
inline void f();
void f() {}
What happens at the redeclaration of f
? Is f
still considered inline
?
I looked in the standard for this situation but I only found the reverse of it in 10.1.6/6 [dcl.inline]:
[...] If the definition of a function or variable appears in a translation unit before its first declaration as inline, the program is ill-formed. [...]
I would like some references in the standard which specify what happens in this situation.
I saw this post on stackoverflow, but it doesn't show an explicit reference in the standard. I'm inclined to believe there is no such reference.
Thank you.
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-discussion+unsubscribe@isocpp.org.
To post to this group, send email to std-dis...@isocpp.org.
Visit this group at https://groups.google.com/a/isocpp.org/group/std-discussion/.
[basic.link]/10
To unsubscribe from this group and stop receiving emails from it, send an email to std-discussio...@isocpp.org.
To unsubscribe from this group and stop receiving emails from it, send an email to std-discussion+unsubscribe@isocpp.org.