Make things print right-ish.
Make things print right-ish.

--- a/include/boilerplate.hpp
+++ b/include/boilerplate.hpp
@@ -4,6 +4,7 @@
 #include <cwchar>

 #include <functional>

 #include <string>

+#include <iostream>

 #include <random>

 #include <memory>

 

@@ -35,7 +36,7 @@
 {

     size_t size = swprintf( nullptr, 0, format.c_str(), args ... ) + 1; // Extra space for '\0'

     std::unique_ptr<c16[]> buf( new c16[ size ] );

-    snwprintf( buf.get(), size, format.c_str(), args ... );

+    swprintf( buf.get(), size, format.c_str(), args ... );

     return wstring( buf.get(), buf.get() + size - 1 ); // We don't want the '\0' inside

 }

 

@@ -56,16 +57,14 @@
 void printline(const c8* format,  params... args) {

 	auto s = string_format(format, args ...);

 

-	printf(s.data());

-	printf(_endl);

+	std::cout << s << _endl;

 }

 

 template<typename...  params>

 void printline(const c16* format,  params... args) {

 	auto s = string_format(format, args ...);

 

-	wprintf(s.data());

-	wprintf(_wendl);

+	std::wcout << s << _wendl;

 }

 

 template<typename...  params>