We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
endsWith
string_views
1 parent 0a5b446 commit cf463f9Copy full SHA for cf463f9
packages/host/cpp/AddonRegistry.cpp
@@ -30,7 +30,7 @@ napi_status napi_emplace_named_property_object(napi_env env,
30
return status;
31
}
32
33
-bool endsWith(const std::string &str, const std::string &suffix) {
+bool endsWith(const std::string_view &str, const std::string_view &suffix) {
34
#if __cplusplus >= 202002L // __cpp_lib_starts_ends_with
35
return str.ends_with(suffix);
36
#else
0 commit comments