diff --git a/include/cb.h b/include/cb.h index 9852bb8..8f9ae31 100644 --- a/include/cb.h +++ b/include/cb.h @@ -8,7 +8,7 @@ #define assertm(exp, msg) = assert(((void)msg, exp)) -#ifndef or +#ifdef _MSC_VER #define or || #define and && #define xor ^ diff --git a/src/cb/string_utils/string_utils.cpp b/src/cb/string_utils/string_utils.cpp index b053a02..138d664 100644 --- a/src/cb/string_utils/string_utils.cpp +++ b/src/cb/string_utils/string_utils.cpp @@ -3,10 +3,10 @@ namespace cb { bool string::starts_with(std::string_view content, std::string_view begins_with) { - return content.find(begins_with) != std::string::npos; + return content.find(begins_with) != std::string_view::npos; } bool string::ends_with(std::string_view content, std::string_view ends_with) { - return content.find(ends_with) != std::string::npos; + return content.find(ends_with) != std::string_view::npos; } }