diff --git a/lang/ast/expr/arith.c b/lang/ast/expr/arith.c index 7657426..fb36d2a 100644 --- a/lang/ast/expr/arith.c +++ b/lang/ast/expr/arith.c @@ -598,7 +598,7 @@ struct token_parse_result arith_parse_left_paren( struct ivy_ast_node *msg = b_unbox(struct ivy_ast_node, msg_entry, n_entry); - if (msg->n_type != IVY_AST_MSG) { + if (!msg || msg->n_type != IVY_AST_MSG) { /* this is not a complex message, it's probably a * call-operator */ goto not_complex_msg;