mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-03 05:08:14 +00:00
Correct Multi Pointer Type handling in expressions
This commit is contained in:
@@ -8486,6 +8486,7 @@ ExprKind check_expr_base_internal(CheckerContext *c, Operand *o, Ast *node, Type
|
|||||||
case Ast_PolyType:
|
case Ast_PolyType:
|
||||||
case Ast_ProcType:
|
case Ast_ProcType:
|
||||||
case Ast_PointerType:
|
case Ast_PointerType:
|
||||||
|
case Ast_MultiPointerType:
|
||||||
case Ast_ArrayType:
|
case Ast_ArrayType:
|
||||||
case Ast_DynamicArrayType:
|
case Ast_DynamicArrayType:
|
||||||
case Ast_StructType:
|
case Ast_StructType:
|
||||||
@@ -8931,6 +8932,11 @@ gbString write_expr_to_string(gbString str, Ast *node, bool shorthand) {
|
|||||||
str = write_expr_to_string(str, pt->type, shorthand);
|
str = write_expr_to_string(str, pt->type, shorthand);
|
||||||
case_end;
|
case_end;
|
||||||
|
|
||||||
|
case_ast_node(pt, MultiPointerType, node);
|
||||||
|
str = gb_string_appendc(str, "[^]");
|
||||||
|
str = write_expr_to_string(str, pt->type, shorthand);
|
||||||
|
case_end;
|
||||||
|
|
||||||
case_ast_node(at, ArrayType, node);
|
case_ast_node(at, ArrayType, node);
|
||||||
str = gb_string_append_rune(str, '[');
|
str = gb_string_append_rune(str, '[');
|
||||||
if (at->count != nullptr &&
|
if (at->count != nullptr &&
|
||||||
|
|||||||
Reference in New Issue
Block a user