[clang] Adding `asuint` implementation to hlsl (PR #107292)
via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 12 13:50:32 PDT 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff 447b32fb192b90be00164a027f990e16c0325de3 d2f55b360d65b8fea16aaab6bba9d7da284d6e49 --extensions h -- clang/lib/Headers/hlsl/hlsl_details.h clang/lib/Headers/hlsl/hlsl_intrinsics.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/lib/Headers/hlsl/hlsl_details.h b/clang/lib/Headers/hlsl/hlsl_details.h
index 1aff524da6..1184b0ef0f 100644
--- a/clang/lib/Headers/hlsl/hlsl_details.h
+++ b/clang/lib/Headers/hlsl/hlsl_details.h
@@ -15,11 +15,13 @@ namespace __details {
template <bool B, typename T> struct enable_if {};
-template <typename T> struct enable_if<true, T> { using Type = T; };
+template <typename T> struct enable_if<true, T> {
+ using Type = T;
+};
template <typename U, typename T, int N>
HLSL_INLINE_ATTRIBUTE
- typename enable_if<sizeof(U) == sizeof(T), vector<U, N> >::Type
+ typename enable_if<sizeof(U) == sizeof(T), vector<U, N>>::Type
bit_cast(vector<T, N> V) {
return __builtin_bit_cast(vector<U, N>, V);
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/107292
More information about the cfe-commits
mailing list