@@ -302,29 +302,21 @@ NBL_CONSTEXPR_STATIC_INLINE bool is_spirv_type_v = is_spirv_type<T>::value;
302
302
303
303
template<class T>
304
304
struct is_unsigned : impl::base_type_forwarder<impl::is_unsigned, typename remove_cv<T>::type> {};
305
- template<class T>
306
- NBL_CONSTEXPR_STATIC_INLINE bool is_unsigned_v = is_unsigned<T>::value;
307
305
308
306
template<class T>
309
307
struct is_integral : impl::base_type_forwarder<impl::is_integral, typename remove_cv<T>::type> {};
310
- template<class T>
311
- NBL_CONSTEXPR_STATIC_INLINE bool is_integral_v = is_integral<T>::value;
312
308
313
309
template<class T>
314
310
struct is_floating_point : impl::base_type_forwarder<impl::is_floating_point, typename remove_cv<T>::type> {};
315
311
316
312
template<class T>
317
313
struct is_signed : impl::base_type_forwarder<impl::is_signed, typename remove_cv<T>::type> {};
318
- template<class T>
319
- NBL_CONSTEXPR_STATIC_INLINE bool is_signed_v = is_signed<T>::value;
320
314
321
315
template<class T>
322
316
struct is_scalar : bool_constant<
323
317
impl::is_integral<typename remove_cv<T>::type>::value ||
324
318
impl::is_floating_point<typename remove_cv<T>::type>::value
325
319
> {};
326
- template<class T>
327
- NBL_CONSTEXPR_STATIC_INLINE bool is_scalar_v = is_scalar<T>::value;
328
320
329
321
template<class T>
330
322
struct is_const : bool_constant<false > {};
@@ -396,13 +388,8 @@ struct enable_if {};
396
388
template<class T>
397
389
struct enable_if<true , T> : type_identity<T> {};
398
390
399
- template<bool B, class T = void >
400
- using enable_if_t = typename enable_if<B, T>::type;
401
-
402
391
template<class T>
403
392
struct alignment_of;
404
- template<class T>
405
- NBL_CONSTEXPR_STATIC_INLINE uint32_t alignment_of_v = alignment_of<T>::value;
406
393
407
394
template<class >
408
395
struct make_void { using type = void ; };
@@ -527,9 +514,6 @@ using is_unbounded_array = std::is_unbounded_array<T>;
527
514
template<class T>
528
515
using is_scalar = std::is_scalar<T>;
529
516
530
- template<class T>
531
- NBL_CONSTEXPR_STATIC_INLINE bool is_scalar_v = is_scalar<T>::value;
532
-
533
517
template<class T>
534
518
struct is_signed : impl::base_type_forwarder<std::is_signed, T> {};
535
519
@@ -539,9 +523,6 @@ struct is_unsigned : impl::base_type_forwarder<std::is_unsigned, T> {};
539
523
template<class T>
540
524
struct is_integral : impl::base_type_forwarder<std::is_integral, T> {};
541
525
542
- template<class T>
543
- NBL_CONSTEXPR_STATIC_INLINE bool is_integral_v = is_integral<T>::value;
544
-
545
526
template<class T>
546
527
struct is_floating_point : impl::base_type_forwarder<std::is_floating_point, T> {};
547
528
@@ -590,9 +571,6 @@ using extent = std::extent<T, I>;
590
571
template<bool B, class T = void >
591
572
using enable_if = std::enable_if<B, T>;
592
573
593
- template<bool B, class T = void >
594
- using enable_if_t = typename enable_if<B, T>::type;
595
-
596
574
template<class T>
597
575
using alignment_of = std::alignment_of<T>;
598
576
@@ -614,9 +592,26 @@ using make_unsigned = std::make_unsigned<T>;
614
592
615
593
#endif
616
594
595
+ // Template Types
596
+ template<bool B, class T = void >
597
+ using enable_if_t = typename enable_if<B,T>::type;
598
+ template<bool C, class T, class F>
599
+ using conditional_t = typename conditional<C,T,F>::type;
600
+
601
+
617
602
// Template Variables
618
603
template<typename A, typename B>
619
- NBL_CONSTEXPR bool is_same_v = is_same<A,B>::value;
604
+ NBL_CONSTEXPR bool is_same_v = is_same<A, B>::value;
605
+ template<class T>
606
+ NBL_CONSTEXPR bool is_unsigned_v = is_unsigned<T>::value;
607
+ template<class T>
608
+ NBL_CONSTEXPR bool is_integral_v = is_integral<T>::value;
609
+ template<class T>
610
+ NBL_CONSTEXPR bool is_signed_v = is_signed<T>::value;
611
+ template<class T>
612
+ NBL_CONSTEXPR bool is_scalar_v = is_scalar<T>::value;
613
+ template<class T>
614
+ NBL_CONSTEXPR uint32_t alignment_of_v = alignment_of<T>::value;
620
615
621
616
// Overlapping definitions
622
617
template<bool C, typename T, T A, T B>
0 commit comments