From 7a269e185fc59e5f81e7c91e6e75891ba2ca4b3b Mon Sep 17 00:00:00 2001 From: crupest Date: Sun, 6 Jun 2021 23:43:52 +0800 Subject: import(life): ... --- works/life/computer-network-experiment/Common.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'works/life/computer-network-experiment/Common.h') diff --git a/works/life/computer-network-experiment/Common.h b/works/life/computer-network-experiment/Common.h index 45a7da1..4e30439 100644 --- a/works/life/computer-network-experiment/Common.h +++ b/works/life/computer-network-experiment/Common.h @@ -14,8 +14,6 @@ inline auto &output_stream = std::wcout; inline auto &error_stream = std::wcerr; #define CRUT(string_literal) L##string_literal -int Main(); - inline String ConvertCharString(std::string_view s) { return cru::ToUtf16WString(s); } @@ -28,12 +26,16 @@ inline auto &output_stream = std::cout; inline auto &error_stream = std::cerr; #define CRUT(string_literal) string_literal -inline String ConvertCharString(std::string_view s) { return s; } +inline String ConvertCharString(std::string_view s) { return String(s); } #endif +int Main(); + [[noreturn]] void PrintErrorMessageAndExit(StringView message, bool print_last_error = true); #ifdef WIN32 void InitWSA(); #endif + +int Close(int socket); -- cgit v1.2.3