You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
experimental/users/jblespiau/tensorfn/pybind11/pmap_function.cc:72:30: error: invalid operands to binary expression ('xt::xall_tag' and 'xt::xall_tag')
bool c = xt::all() == xt::all();
~~~~~~~~~ ^ ~~~~~~~~~
./third_party/xtensor/xutils.hpp:737:17: note: candidate template ignored: could not match 'tracking_allocator<T, AT, PT>' against 'xt::xall_tag'
inline bool operator==(const tracking_allocator<T, AT, PT>&, const tracking_allocator<U, AU, PU>&)
^
./third_party/xtensor/xstorage.hpp:545:17: note: candidate template ignored: could not match 'uvector<T, A>' against 'xt::xall_tag'
inline bool operator==(const uvector<T, A>& lhs, const uvector<T, A>& rhs)
^
./third_party/xtensor/xstorage.hpp:1270:17: note: candidate template ignored: could not match 'std::vector<T>' against 'xt::xall_tag'
inline bool operator==(const std::vector<T>& lhs, const svector<T, N, A, Init>& rhs)
^
./third_party/xtensor/xstorage.hpp:1276:17: note: candidate template ignored: could not match 'svector<T, N, A, Init>' against 'xt::xall_tag'
inline bool operator==(const svector<T, N, A, Init>& lhs, const std::vector<T>& rhs)
^
experimental/users/jblespiau/tensorfn/pybind11/pmap_function.cc:72:30: note: remaining 9 candidates omitted; pass -fshow-overloads=all to show them
bool c = xt::all() == xt::all();
Sorry for the late reply. The issue is indseed dut to the lack of coparison operators for the slices, that's something we should add in xtensor.
Regarding the upgrade to C++17, it has been discussed for xtensor. However, the XTL is also used by libraries which needs to support C++11/14, thus the need for a backport of std::variant. We are happy with this backport (easier to update than retrieving it from a huge library), but we could definitely add a "selection" layer here, that will simply use the standard implementation when available.
It's as simple as doing:
xt::all() == xt::all()
The type is defined as:
As a side-note, I was wondering if we should upgrade to C++ 17 to use std::variant instead of a backport. Another altnertive would be to use e.g. https://github.com/abseil/abseil-cpp/blob/master/absl/types/variant.h which will be an alias to
std::variant
when available.The text was updated successfully, but these errors were encountered: