C++ Syntax Guide?
I am good in C++ concepts but I'm having hard time in understanding C++ syntax. Like in this example why ":elem" is written before curly braces.
And this is a different for loop syntax.
Can you guide me where can I learn this type of advanced syntax?
asked Feb 08 '15 at 09:50 AM in C++ Programming
Easy one first: That's C++11's new range based for loop. 1-(Epic range based for loop blog) 2-(range-based for loop) 3-(Epic's coding standard about range based for loop)
So that ":elem" stuff is part of basic c++ constructor semantics, used poorly. For your reference: member initializer list.
Follow UE coding standard. Than you would have been able to see whats going on. Probably a good college text book updated with C++11/14. Though only as far as Epic uses the C++11 features.
answered Feb 08 '15 at 07:18 PM
I learned C++11 syntax through Stroustrup's book. If you already have a working knowledge of C++, it's a great book as it goes into detail on this stuff in the first few chapters. http://www.amazon.com/The-Programming-Language-4th-Edition/dp/0321563840/ref=dp_ob_title_bk
answered Feb 09 '15 at 12:51 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here