diff --git a/include/ylt/util/function_name.h b/include/ylt/util/function_name.h index b36cac044..bc47f433a 100644 --- a/include/ylt/util/function_name.h +++ b/include/ylt/util/function_name.h @@ -21,8 +21,7 @@ using namespace std::string_view_literals; template -constexpr std::string_view string_view_array_has( - const std::array& array, std::string_view value) { +constexpr std::string_view string_view_array_has(const std::array& array, std::string_view value) { for (const auto& v : array) { if (value.find(v) == 0) return v; @@ -34,20 +33,17 @@ namespace coro_rpc { template constexpr std::string_view get_func_name() { constexpr std::array func_style_array { - std::string_view{"__cdecl "}, - std::string_view{"__clrcall "}, - std::string_view{"__stdcall "}, - std::string_view{"__fastcall "}, - std::string_view{"__thiscall "}, - std::string_view{"__vectorcall "} + std::string_view{"__cdecl "}, + std::string_view{"__clrcall "}, + std::string_view{"__stdcall "}, + std::string_view{"__fastcall "}, + std::string_view{"__thiscall "}, + std::string_view{"__vectorcall "} }; - constexpr auto qualified_name = - std::string_view{refvalue::qualified_name_of_v}; - constexpr auto func_style = - string_view_array_has(func_style_array, qualified_name); + constexpr auto qualified_name = std::string_view{refvalue::qualified_name_of_v}; + constexpr auto func_style = string_view_array_has(func_style_array, qualified_name); if constexpr (func_style.length() > 0) { - return std::string_view{qualified_name.data() + func_style.length(), - qualified_name.length() - func_style.length()}; + return std::string_view{qualified_name.data() + func_style.length(), qualified_name.length() - func_style.length()}; } return qualified_name; }; diff --git a/src/coro_rpc/examples/base_examples/rpc_service.cpp b/src/coro_rpc/examples/base_examples/rpc_service.cpp index 8dbbddd8f..6b0b48854 100644 --- a/src/coro_rpc/examples/base_examples/rpc_service.cpp +++ b/src/coro_rpc/examples/base_examples/rpc_service.cpp @@ -31,7 +31,7 @@ std::string hello_world() { } bool return_bool_hello_world() { - return true; + return true; } int A_add_B(int a, int b) {