3 ms·
>And how would you even write this snippet, pre auto?! typeof(t1 + t2) sum = t1 + t2;
by koenigdavidmj 15y ago
>And how would you even write this snippet, pre auto?!
typeof(t1 + t2) sum = t1 + t2;
- koenigdavidmj 15y agoThat should be decltype, not typeof, btw
- dilap 15y agoThat's cheating! I meant how would you write it pre-C++11 extensions (and also not using the earlier GCC typeof extension). decltype is just a slightly different form of auto. :)