mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-10 05:57:51 +00:00
Make dawn_native use the webgpu.h header
BUG=dawn:22 Change-Id: I66e2d998f5e09030e40ec88813cd65c492018fd0 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/12541 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Kai Ninomiya <kainino@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
c833c0c592
commit
1f6c8c4d54
@@ -17,16 +17,6 @@
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
namespace dawn {
|
||||
|
||||
template <typename T>
|
||||
constexpr bool HasZeroOrOneBits(T value) {
|
||||
using Integral = typename std::underlying_type<T>::type;
|
||||
return (static_cast<Integral>(value) & (static_cast<Integral>(value) - 1)) == 0;
|
||||
}
|
||||
|
||||
} // namespace dawn
|
||||
|
||||
namespace wgpu {
|
||||
|
||||
template <typename T>
|
||||
@@ -142,6 +132,13 @@ namespace wgpu {
|
||||
l = l ^ r;
|
||||
return l;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
constexpr bool HasZeroOrOneBits(T value) {
|
||||
using Integral = typename std::underlying_type<T>::type;
|
||||
return (static_cast<Integral>(value) & (static_cast<Integral>(value) - 1)) == 0;
|
||||
}
|
||||
|
||||
} // namespace wgpu
|
||||
|
||||
#endif // DAWN_ENUM_CLASS_BITMASKS_H_
|
||||
|
||||
Reference in New Issue
Block a user