commit | 4135ea55eb263b9b189c410afce7dee97ac1fd38 | [log] [tgz] |
---|---|---|
author | Ben Clayton <bclayton@google.com> | Mon Jul 05 15:20:57 2021 +0000 |
committer | Tint LUCI CQ <tint-scoped@luci-project-accounts.iam.gserviceaccount.com> | Mon Jul 05 15:20:57 2021 +0000 |
tree | 6f6ed33ccc455dfc29c963e7d63c123a69ef0d30 | |
parent | 106ac290e6ccb420be7d6f0eb10f75a19cc9a8e8 [diff] |
writer/hlsl: Don't wrap arrays in structures FXC has trouble dealing with these. This was originally added to handle returning arrays as structures. HLSL supports typedefs, which is a much simpiler solution, and doesn't upset FXC. Bug: tint:848 Bug: tint:904 Change-Id: Ie841c9c454461a885a35c41476fd4d05d3f34cbf Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/56774 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Antonio Maiorano <amaiorano@google.com> Commit-Queue: Ben Clayton <bclayton@google.com>
diff --git a/test/expressions/zero_init/struct/array.wgsl.expected.hlsl b/test/expressions/zero_init/struct/array.wgsl.expected.hlsl index c514b14..6b9d582 100644 --- a/test/expressions/zero_init/struct/array.wgsl.expected.hlsl +++ b/test/expressions/zero_init/struct/array.wgsl.expected.hlsl
@@ -3,11 +3,8 @@ return; } -struct tint_array_wrapper { - float arr[4]; -}; struct S { - tint_array_wrapper a; + float a[4]; }; void f() {