News for hackers. Stuff that matters.
Re:Elements of Modern C++ Style by koenigdavidmj on Saturday October 29, 2011 @04:45PM (#3172757)
>And how would you even write this snippet, pre auto?!

  typeof(t1 + t2) sum = t1 + t2;
Re:Elements of Modern C++ Style by dilap on Saturday October 29, 2011 @05:43PM (#3172887)
That'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. :)
Re:Elements of Modern C++ Style by koenigdavidmj on Saturday October 29, 2011 @04:50PM (#3172772)
That should be decltype, not typeof, btw