Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
rolandschulz committed Dec 25, 2023
1 parent 5533840 commit fcd3080
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 15 deletions.
20 changes: 8 additions & 12 deletions sycl/include/sycl/ext/oneapi/properties/properties.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -247,22 +247,18 @@ template <typename SyclT, typename PropertiesT>
struct all_props_are_keys_of : std::true_type {};

template <typename SyclT>
struct all_props_are_keys_of<
SyclT, empty_properties_t>
: std::true_type {};
struct all_props_are_keys_of<SyclT, empty_properties_t> : std::true_type {};

template <typename SyclT, typename PropT>
struct all_props_are_keys_of<
SyclT, properties<std::tuple<PropT>>>
: std::bool_constant<is_property_key_of<
key_from_value<PropT>, SyclT>::value> {};
struct all_props_are_keys_of<SyclT, properties<std::tuple<PropT>>>
: std::bool_constant<
is_property_key_of<key_from_value<PropT>, SyclT>::value> {};

template <typename SyclT, typename PropT, typename... PropTs>
struct all_props_are_keys_of<
SyclT, properties<std::tuple<PropT, PropTs...>>>
: std::bool_constant<is_property_key_of<
key_from_value<PropT>, SyclT>::value &&
all_props_are_keys_of<SyclT, PropTs...>()> {};
struct all_props_are_keys_of<SyclT, properties<std::tuple<PropT, PropTs...>>>
: std::bool_constant<
is_property_key_of<key_from_value<PropT>, SyclT>::value &&
all_props_are_keys_of<SyclT, PropTs...>()> {};

} // namespace detail
} // namespace ext::oneapi::experimental
Expand Down
3 changes: 2 additions & 1 deletion sycl/include/sycl/ext/oneapi/properties/property_value.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ template <typename V>
using is_property_value = is_property_key<detail::key_from_value_or_void<V>>;

template <typename V, typename O>
using is_property_value_of = is_property_key_of<detail::key_from_value_or_void<V>, O>;
using is_property_value_of =
is_property_key_of<detail::key_from_value_or_void<V>, O>;

namespace detail {

Expand Down
3 changes: 1 addition & 2 deletions sycl/test/extensions/annotated_usm/fake_properties.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ template <> struct property_value<foz_key> {
using value_t = property_value<rt_prop##N##_key>; \
}; \
using rt_prop##N = property_value<rt_prop##N##_key>; \
template <> struct property_value<rt_prop##N##_key> { \
}
template <> struct property_value<rt_prop##N##_key> {}

rt_prop(1);
rt_prop(2);
Expand Down

0 comments on commit fcd3080

Please sign in to comment.