Skip to content

Commit

Permalink
[mac] Fix macOS builds with Xcode 11.3
Browse files Browse the repository at this point in the history
  • Loading branch information
jcelerier committed Nov 18, 2022
1 parent 675ecf3 commit 82e059d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/ossia/detail/ssize.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include <version>
// MacOSX11.3 SDK provides ssize but does not define it...
#if __cpp_lib_ssize >= 201902L \
|| (__MAC_OS_X_VERSION_MIN_REQUIRED >= 113000 && _LIBCPP_STD_VER > 17) \
|| (__MAC_OS_X_VERSION_MIN_REQUIRED >= 114000 && _LIBCPP_STD_VER > 17) \
|| defined(__EMSCRIPTEN__)
#include <iterator>
#define OSSIA_HAS_STD_SSIZE 1
Expand Down
4 changes: 2 additions & 2 deletions src/ossia/network/common/path.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ namespace ossia::traversal
using rexp = std::shared_ptr<re2::RE2>;
static inline bool rexp_match(std::string_view m, const rexp& r)
{
return re2::RE2::FullMatch(m, *r);
return re2::RE2::FullMatch(re2::StringPiece(m.data(), m.size()), *r);
}

void apply(const path& p, std::vector<ossia::net::node_base*>& nodes)
Expand Down Expand Up @@ -369,7 +369,7 @@ bool match(const path& p, const ossia::net::node_base& node, ossia::net::node_ba
bool match(std::string_view address, const regex_path::path_element& e)
{
re2::RE2 rex{e.address};
return re2::RE2::FullMatch(address, rex);
return re2::RE2::FullMatch(re2::StringPiece(address.data(), address.size()), rex);
}

}
Expand Down

0 comments on commit 82e059d

Please sign in to comment.