I can't compliment csdn's blog layout. It took me several hours to translate the first part of this blog and publish the result.CodePartially disordered.
It took another quarter of a second to edit and retypeset online in the csdn editor! I really can't stand it.
If you look unhappy friends can look here: http://www.cnblogs.com/brucejia/archive/2009/09/05/1560675.html
[Most of the content translated from Visual C ++ team blog] http://blogs.msdn.com/vcblog/archive/2008/10/28/lambdas-auto-and-static-assert-c-0x-features-in-vc10-part-1.aspx
Please post: http://blog.csdn.net/IDisposable/archive/2009/09/03/4517158.aspx
Although C ++CommunityC ++ 0x is very popular, but vendors are not enthusiastic about the support for new standards. Looking forward to the stars and the moon, Microsoft, as the most powerful C ++ compiler vendor on the Windows platform, finally began to support the C ++ 0x feature in Visual Studio 2010.
Lambda expressions, auto and static assertions (static_assert)
In Visual Studio 2010, the visual C ++ compiler, VC10, contains four C ++ 0x language features-lambda expressions, auto, static_assert, and rvalue reference (right value reference ).
Related links:
- C ++ 0x language feature status: http://open-std.org/JTC1/SC22/WG21/docs/papers/2008/n2705.html
- C ++ 0x library feature status: http://open-std.org/JTC1/SC22/WG21/docs/papers/2008/n2706.html
- C ++ 0x Working Draft: http://open-std.org/JTC1/SC22/WG21/docs/papers/2008/n2798.pdf
Lambda expressions
Functional Method UsedProgramming Language(Such as LISP, F #) or some dynamic languages (such as Python and JavaScript) are familiar with Lambda expressions.
In C ++ 0x, lambda expressions are introduced to define unsung functions. Below is a simple example of a Lambda expression:
[I wanted to arrange the layout well. After several attempts, I finally gave up the fate of failure. Thank you for your support and encouragement.]
Please go to cnblog to see if the layout is normal.
Http://www.cnblogs.com/brucejia/