Skip to content

Commit 20ea47f

Browse files
committed
fix: PGI void_t only
1 parent a1cd376 commit 20ea47f

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

include/pybind11/detail/common.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -501,8 +501,12 @@ template <bool... Bs> using select_indices = typename select_indices_impl<index_
501501
template <bool B> using bool_constant = std::integral_constant<bool, B>;
502502
template <typename T> struct negation : bool_constant<!T::value> { };
503503

504-
template <typename... >
505-
using void_t = void;
504+
#if defined(__PGIC__)
505+
template<typename... > using void_t = void;
506+
#else
507+
template<typename... Ts> struct make_void { typedef void type;};
508+
template<typename... Ts> using void_t = typename make_void<Ts...>::type;
509+
#endif
506510

507511

508512
/// Compile-time all/any/none of that check the boolean value of all template types

0 commit comments

Comments
 (0)