mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-06 22:08:41 +00:00
eval irgen: allow ,length fastpath for array types as well
This commit is contained in:
+6
-1
@@ -2312,7 +2312,11 @@ e_irtree_and_type_from_expr(Arena *arena, E_Expr *root_expr)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(!matches_shorthand && e_type_kind_is_pointer_or_ref(e_type_kind_from_key(e_type_key_unwrap(result.type_key, E_TypeUnwrapFlag_AllDecorative))))
|
if(!matches_shorthand)
|
||||||
|
{
|
||||||
|
E_TypeKind type_kind = e_type_kind_from_key(e_type_key_unwrap(result.type_key, E_TypeUnwrapFlag_AllDecorative));
|
||||||
|
if(e_type_kind_is_pointer_or_ref(type_kind) ||
|
||||||
|
type_kind == E_TypeKind_Array)
|
||||||
{
|
{
|
||||||
E_Expr *lens_spec_expr = e_string2expr_lookup(e_ir_state->ctx->macro_map, str8_lit("array"));
|
E_Expr *lens_spec_expr = e_string2expr_lookup(e_ir_state->ctx->macro_map, str8_lit("array"));
|
||||||
E_TypeKey lens_spec_type_key = lens_spec_expr->type_key;
|
E_TypeKey lens_spec_type_key = lens_spec_expr->type_key;
|
||||||
@@ -2329,6 +2333,7 @@ e_irtree_and_type_from_expr(Arena *arena, E_Expr *root_expr)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//- rjf: if the evaluated type has a hook for an extra layer of ir extension,
|
//- rjf: if the evaluated type has a hook for an extra layer of ir extension,
|
||||||
// call into it
|
// call into it
|
||||||
|
|||||||
Reference in New Issue
Block a user