diff --git a/include/OpenABF/MeshIOUtils.hpp b/include/OpenABF/MeshIOUtils.hpp index 3df5b43..64e71ec 100644 --- a/include/OpenABF/MeshIOUtils.hpp +++ b/include/OpenABF/MeshIOUtils.hpp @@ -33,8 +33,8 @@ static auto icase_compare(const std::string_view a, const std::string_view b) -> static auto trim_left(std::string_view s) -> std::string_view { const auto& loc = std::locale(); - const auto* start = std::find_if_not(std::begin(s), std::end(s), - [&loc](auto ch) -> bool { return std::isspace(ch, loc); }); + const auto start = std::find_if_not(std::begin(s), std::end(s), + [&loc](auto ch) -> bool { return std::isspace(ch, loc); }); s.remove_prefix(std::distance(std::begin(s), start)); return s; } @@ -43,9 +43,9 @@ static auto trim_left(std::string_view s) -> std::string_view static auto trim_right(std::string_view s) -> std::string_view { const auto& loc = std::locale(); - const auto* start = std::find_if_not(s.rbegin(), s.rend(), [&loc](auto ch) -> bool { - return std::isspace(ch, loc); - }).base(); + const auto start = std::find_if_not(s.rbegin(), s.rend(), [&loc](auto ch) -> bool { + return std::isspace(ch, loc); + }).base(); s.remove_suffix(std::distance(start, std::end(s))); return s; } diff --git a/single_include/OpenABF/OpenABF.hpp b/single_include/OpenABF/OpenABF.hpp index 9296180..d2d48c5 100644 --- a/single_include/OpenABF/OpenABF.hpp +++ b/single_include/OpenABF/OpenABF.hpp @@ -4435,8 +4435,8 @@ static auto icase_compare(const std::string_view a, const std::string_view b) -> static auto trim_left(std::string_view s) -> std::string_view { const auto& loc = std::locale(); - const auto* start = std::find_if_not(std::begin(s), std::end(s), - [&loc](auto ch) -> bool { return std::isspace(ch, loc); }); + const auto start = std::find_if_not(std::begin(s), std::end(s), + [&loc](auto ch) -> bool { return std::isspace(ch, loc); }); s.remove_prefix(std::distance(std::begin(s), start)); return s; } @@ -4445,9 +4445,9 @@ static auto trim_left(std::string_view s) -> std::string_view static auto trim_right(std::string_view s) -> std::string_view { const auto& loc = std::locale(); - const auto* start = std::find_if_not(s.rbegin(), s.rend(), [&loc](auto ch) -> bool { - return std::isspace(ch, loc); - }).base(); + const auto start = std::find_if_not(s.rbegin(), s.rend(), [&loc](auto ch) -> bool { + return std::isspace(ch, loc); + }).base(); s.remove_suffix(std::distance(start, std::end(s))); return s; }