@@ -508,7 +508,7 @@ template <class T> class [[nodiscard]] Expected {
508
508
// / must be convertible to T.
509
509
template <typename OtherT>
510
510
Expected (OtherT &&Val,
511
- std::enable_if_t <std::is_convertible <OtherT, T>::value > * = nullptr )
511
+ std::enable_if_t <std::is_convertible_v <OtherT, T>> * = nullptr )
512
512
: HasError (false )
513
513
#if LLVM_ENABLE_ABI_BREAKING_CHECKS
514
514
// Expected is unchecked upon construction in Debug builds.
@@ -525,9 +525,8 @@ template <class T> class [[nodiscard]] Expected {
525
525
// / Move construct an Expected<T> value from an Expected<OtherT>, where OtherT
526
526
// / must be convertible to T.
527
527
template <class OtherT >
528
- Expected (
529
- Expected<OtherT> &&Other,
530
- std::enable_if_t <std::is_convertible<OtherT, T>::value> * = nullptr ) {
528
+ Expected (Expected<OtherT> &&Other,
529
+ std::enable_if_t <std::is_convertible_v<OtherT, T>> * = nullptr ) {
531
530
moveConstruct (std::move (Other));
532
531
}
533
532
@@ -536,7 +535,7 @@ template <class T> class [[nodiscard]] Expected {
536
535
template <class OtherT >
537
536
explicit Expected (
538
537
Expected<OtherT> &&Other,
539
- std::enable_if_t <!std::is_convertible <OtherT, T>::value > * = nullptr ) {
538
+ std::enable_if_t <!std::is_convertible_v <OtherT, T>> * = nullptr ) {
540
539
moveConstruct (std::move (Other));
541
540
}
542
541
0 commit comments