diff --git a/llvm/include/llvm/ADT/iterator_range.h b/llvm/include/llvm/ADT/iterator_range.h --- a/llvm/include/llvm/ADT/iterator_range.h +++ b/llvm/include/llvm/ADT/iterator_range.h @@ -24,16 +24,6 @@ namespace llvm { -template -struct explicitly_convertible : std::false_type {}; - -template -struct explicitly_convertible< - From, To, - std::void_t( - std::declval>()))>> : std::true_type { -}; - /// A range adaptor for a pair of iterators. /// /// This just wraps two iterators into a range-compatible interface. Nothing @@ -43,9 +33,10 @@ IteratorT begin_iterator, end_iterator; public: - template , IteratorT>::value> * = nullptr> + // TODO: Add SFINAE to test that the Container's iterators match the range's + // iterators. Be careful no to break gcc-7 on the mlir target. + // See https://github.com/llvm/llvm-project/issues/63843 + template iterator_range(Container &&c) : begin_iterator(adl_begin(std::forward(c))), end_iterator(adl_end(std::forward(c))) {}