diff --git a/src/util/string.hpp b/src/util/string.hpp index c6149391..ab835e39 100644 --- a/src/util/string.hpp +++ b/src/util/string.hpp @@ -222,7 +222,8 @@ String make_non_capturing(const String& re); // ----------------------------------------------------------------------------- : Iterator utilities -struct end_sentinel_t {} end_sentinel; +struct end_sentinel_t {}; +const end_sentinel_t end_sentinel; // Iterate over a string, removing all matching substrings. // match.operator(it,end) should return false or return true and advance it past the substring diff --git a/src/util/tagged_string.hpp b/src/util/tagged_string.hpp index 95b414d3..d6c6cb07 100644 --- a/src/util/tagged_string.hpp +++ b/src/util/tagged_string.hpp @@ -220,9 +220,9 @@ String tagged_substr_replace(const String& input, size_t start, size_t end, cons */ bool check_tagged(const String& str, bool check_balance = true); #ifdef _DEBUG - #define assert_tagged(x) assert(check_tagged(x)) + #define assert_tagged(...) assert(check_tagged(__VA_ARGS__)) #else - #define assert_tagged(x) do{}while(0) + #define assert_tagged(...) do{}while(0) #endif /// Simplify a tagged string