11#include " pch.h"
22
33#define WINRT_IMPORT_MODULE
4+ import std;
45import winrt.Windows.Foundation;
56import winrt.Windows.UI.Xaml;
67
@@ -17,10 +18,10 @@ int main()
1718 // Test ModuleTestHelper
1819 auto helper = TestModuleApp::ModuleTestHelper ();
1920 auto uri = helper.CreateUri (L" https://example.com" );
20- printf (" URI: %ls\n " , uri.AbsoluteUri ().c_str ());
21+ std:: printf (" URI: %ls\n " , uri.AbsoluteUri ().c_str ());
2122
2223 auto str = helper.GetStringAsync ().get ();
23- printf (" Async: %ls\n " , str.c_str ());
24+ std:: printf (" Async: %ls\n " , str.c_str ());
2425
2526 // Test CustomDependencyObject (inherits from DependencyObject)
2627 // Note: DependencyObject requires XAML runtime, which isn't available in a console app.
@@ -29,13 +30,13 @@ int main()
2930 {
3031 auto obj = winrt::make<TestModuleApp::implementation::CustomDependencyObject>();
3132 obj.Name (L" test" );
32- printf (" Name: %ls\n " , obj.Name ().c_str ());
33+ std:: printf (" Name: %ls\n " , obj.Name ().c_str ());
3334 }
3435 catch (winrt::hresult_error const & e)
3536 {
36- printf (" CustomDependencyObject: expected runtime error (no XAML host): %ls\n " , e.message ().c_str ());
37+ std:: printf (" CustomDependencyObject: expected runtime error (no XAML host): %ls\n " , e.message ().c_str ());
3738 }
3839
39- printf (" All module tests passed.\n " );
40+ std:: printf (" All module tests passed.\n " );
4041 return 0 ;
4142}
0 commit comments