llr: Fix the type of LayoutCacheAccess

It access the element of the array.
This starts to be important when that expression starts being inlined
in more complex expressions
This commit is contained in:
Olivier Goffart 2022-02-16 16:34:43 +01:00 committed by Olivier Goffart
parent 21546722ad
commit dc3c91dd9f

View file

@ -278,7 +278,7 @@ impl Expression {
Self::LinearGradient { .. } => Type::Brush,
Self::EnumerationValue(e) => Type::Enumeration(e.enumeration.clone()),
Self::ReturnStatement(_) => Type::Invalid,
Self::LayoutCacheAccess { .. } => Type::Array(Type::Int32.into()),
Self::LayoutCacheAccess { .. } => Type::LogicalLength,
Self::BoxLayoutFunction { sub_expression, .. } => sub_expression.ty(ctx),
Self::ComputeDialogLayoutCells { .. } => {
Type::Array(super::lower_expression::grid_layout_cell_data_ty().into())