2012-12-01から1ヶ月間の記事一覧

Visual Studio 2012とWinDbgの統合

かなり遅くなりましたがVisual Studio 2012とWinDbgの統合を試してみました。 といっても単にWDK 8をインストールだけですが。WDKをインストールする前はデバッガとして選択できるのは以下のようになっていました。 インストールすると次のように増えます。 …

Default template arguments for function templatesを試す

November CTP of the C++ compilerのお試しの最後です。 Default template arguments for function templatesを使ってみます。 といっても「C++ Primer 第5版」のサンプルが簡単でわかりやすいのでそのまま入力です。 template <typename T, typename F = std::less<T>> int compare(const T &v1, c</typename>…

Visual C++2012でExplicit conversion operatorsを試す

VC++2012のNovember CTP of the C++ compilerお試しその4。 Explicit conversion operatorsを試します。 というか、「Explicit conversion operators」ってどんな機能なのよ? そのままの意味でconversion operatorsをexplicitにできるということでよいのか…

Visual C++2012でDelegating constructorsを試す

VC++2012のNovember CTP of the C++ compilerお試しその3。 Delegating constructorsを試しましょう。 #include "stdafx.h" #include <iostream> #include <string> class Test { int data_; std::string msg_; public: Test() : Test(123) { std::cout << "Test()" << std::e</string></iostream>…

Visual Studio2012で「Uniform initialization and initializer_lists」を試す

VC++2012のNovember CTP of the C++ compilerお試しその4。 initializer_listを試しましょう。 ですが、コンパイラが対応しただけで、STLの更新はまだみたいなのでvectorとかで使ってみるというわけにはいきません。 一番簡単なサンプル とりあえず、初めて…

Visual C++2012でRaw string literalsをお試し

VC++2012のNovember CTP of the C++ compilerお試しその2。 Raw string literalsとやらを試しましょう。 #include "stdafx.h" #include <iostream> #include <locale> int _tmain(int argc, _TCHAR* argv[]) { std::locale::global(std::locale("japanese")); const char* msg</locale></iostream>…