Presentation: “What`s new in VC++ 2012″ by Rong Lu

Report
for (i = 0; i < 1024; i++)
C[i] = A[i]*B[i];
for (i = 0; i < 1024; i+=4)
C[i:i+3] = A[i:i+3]*B[i:i+3];
#pragma loop(hint_parallel ( N ) )
for (i = 0; i < 1024; i++)
C[i] = A[i]*B[i];
N is the number of
cores you want to
parallelize over
auto type deduction
• Then
• Now
new  make_shared
T*  shared_ptr<T>
circle* p = new circle( 42 );
auto p = make_shared<circle>( 42 );
vector<shape*> vw = load_shapes();
vector<shared_ptr<shape>> vw = load_shapes();
for( vector<circle*>::iterator i = vw.begin(); i != vw.end();
++i ) {
if( *i && **i == *p )
cout << **i << “ is a match\n”;
}
for_each( begin(vw), end(vw), [&]( shared_ptr<circle>& s
){
if( s && *s == *p )
cout << *s << “ is a match\n”;
} );
for( vector<circle*>::iterator i = vw.begin();
i != vw.end(); ++i ) {
delete *i;
not exception-safe
}
delete p;
missing try/catch,
__try/__finally
no need for “delete”
automatic lifetime management
exception-safe
for/while/do 
std:: algorithms
[&] lambda functions
C++11 Core Language Features
Rvalue references
Lambdas
decltype
auto
static_Assert
Trailing return types
nullptr
Strongly typed enums
Forward declared enums
Standard-layout and trivial types
Atomics
Strong compare and exchange
Bidirectional fences
Data-dependency ordering
VC10
v2.0
v1.0
v1.0
v1.0
Yes
Yes
Yes
Partial
No
No
No
No
No
No
VC11
v2.1*
v1.1
v1.1**
v1.0
Yes
Yes
Yes
Yes
Yes
Yes
Yes
Yes
Yes
Yes
 First
class support for building Windows metro style
apps using C++.



XAML/C++ apps
DirectX games
Build your own C++ Windows runtime (WinRT)
component and access it from the language of your
choice: C#, VB, JS, C++






void MainPage::detectButton_Click(Platform::Object^ sender,
Windows::UI::Xaml::RoutedEventArgs^ e)
{
// detectButton handler
FaceFileList->Clear();
WinRTComponent^ faceDetectComponent = ref new WinRTComponent();
auto action = faceDetectComponent>ExtractFacesFromFilesAsync(localSrcFileVector);
}
namespace winrtfacedetect
{
public ref class WinRTComponent sealed
{
public:
WinRTComponent();
IAsyncActionWithProgress<String^>^ ExtractFacesFromFilesAsync(IVector<StorageFile^>^
inFileVector);
IVector<String^>^ SearchFiles(String^ query);
private:
Vector<String^>^ getPathsFromFiles(IVector<StorageFile^>^ inFileVector);
};
}
• IDE enhancements
• Solution explorer
• Project compatibility with VC10
• Reference highlighting
• Member list filtering
• Application Lifecycle management tools
• Architecture discovery tools
• Unit testing
• Code analysis
• Code coverage
http://blogs.msdn.com/vcblog
A lap around Visual Studio 11 Express for Metro style apps using C++
Using the Windows Runtime from C++
Bringing existing C++ code into Metro style apps
Taming GPU compute with C++ AMP
Tips & tricks: how to use Visual Studio to the fullest
Writing modern C++ code: how C++ has evolved over the years
Tips and tricks for developing Metro style apps using C++
Under the covers with C++ for Metro style apps
A lap around DirectX game development tools
First Look at the New C++ IDE Productivity Features in Visual Studio 11
ALM for C++ in Visual Studio 11
What's new in Visual Studio 11 for Application Lifecycle Management
Working on an agile team with Visual Studio 11 and Team Foundation Server 11
Improving software quality using Visual Studio 11 C++ Code Analysis

similar documents