From 29ca53148d217bbb69ef52c17f46e101da79e06b Mon Sep 17 00:00:00 2001 From: teoxoy <28601907+teoxoy@users.noreply.github.com> Date: Thu, 19 Oct 2023 18:08:54 +0200 Subject: [PATCH] fix OOB typifier indexing --- src/front/wgsl/lower/mod.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/front/wgsl/lower/mod.rs b/src/front/wgsl/lower/mod.rs index b9d536cf5f..6ff520e952 100644 --- a/src/front/wgsl/lower/mod.rs +++ b/src/front/wgsl/lower/mod.rs @@ -1707,6 +1707,7 @@ impl<'source, 'temp> Lowerer<'source, 'temp> { crate::TypeInner::Scalar { kind, .. } => kind, crate::TypeInner::Vector { kind, .. } => kind, _ => { + ctx.grow_types(expr)?; let ty = &ctx.typifier()[expr]; return Err(Error::BadTypeCast { from_type: ctx.format_type_resolution(ty),