fix OOB typifier indexing

This commit is contained in:
teoxoy authored and Jim Blandy committed 2023-10-19 09:15:28 -07:00
1 parent af26d77ce4
commit 29ca53148d
1 file changed
+1
+1
View File
@@ -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),