Skip to content

Commit

Permalink
shader/execution: Fix composite abstract runtime indexing (again) (#3659
Browse files Browse the repository at this point in the history
)

Extends the fix of #3484 to cover **nested** composite types.
  • Loading branch information
ben-clayton authored Apr 15, 2024
1 parent eaa860a commit 539e362
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/webgpu/shader/execution/expression/expression.ts
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ function basicExpressionShaderBody(
// Constant eval
//////////////////////////////////////////////////////////////////////////
let body = '';
if (parameterTypes.some(ty => isAbstractType(elementTypeOf(ty)))) {
if (parameterTypes.some(ty => isAbstractType(scalarTypeOf(ty)))) {
// Directly assign the expression to the output, to avoid an
// intermediate store, which will concretize the value early
body = cases
Expand Down

0 comments on commit 539e362

Please sign in to comment.