Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions llvm/include/llvm/ADT/fallible_iterator.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,9 @@ namespace llvm {
/// without requiring redundant error checks.
template <typename Underlying> class fallible_iterator {
private:
template <typename T>
using enable_if_struct_deref_supported = std::enable_if_t<
!std::is_void<decltype(std::declval<T>().operator->())>::value,
decltype(std::declval<T>().operator->())>;
template <typename T, typename U = decltype(std::declval<T>().operator->())>
using enable_if_struct_deref_supported =
std::enable_if_t<!std::is_void_v<U>, U>;

public:
/// Construct a fallible iterator that *cannot* be used as an end-of-range
Expand Down