
18 Mar
2013
18 Mar
'13
10:09 p.m.
On Mon, 18 Mar 2013 08:43:34 -0700, Lorenzo Caminiti
Mostafa, on which compiler did you try to compile the "dangling definition" above in a local scope? As Steven also pointed out, unfortunately this is not valid C++:
int main() { // local scope struct local_add { inline void body(); }; inline void local_add::body() // Invalid :( { } return 0; }
Yes, you're both right. I was too hasty with that suggestion and didn't test it before posting it. Which is funny, because it's the third time I made that very same mistake ...