From febd11fa951b03f6499be141687d8b0e30c23913 Mon Sep 17 00:00:00 2001 From: Christoffer Lerno Date: Mon, 10 Oct 2022 11:55:46 +0200 Subject: [PATCH] Fix of crashing bug with member types. Version bump. --- src/compiler/sema_expr.c | 5 +++-- src/version.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/compiler/sema_expr.c b/src/compiler/sema_expr.c index 4ad2183d7..0b2adf62d 100644 --- a/src/compiler/sema_expr.c +++ b/src/compiler/sema_expr.c @@ -1088,9 +1088,10 @@ INLINE bool sema_call_expand_arguments(SemaContext *context, CalledDecl *callee, else if (variadic == VARIADIC_ANY) { if (!sema_analyse_expr(context, arg)) return false; - if (arg->type == type_untypedlist) + if (type_is_invalid_storage_type(arg->type)) { - SEMA_ERROR(arg, "An untyped list cannot be passed as a variadic argument."); + SEMA_ERROR(arg, "A value of type %s cannot be passed as a variadic argument.", + type_quoted_error_string(arg->type)); return false; } expr_insert_addr(arg); diff --git a/src/version.h b/src/version.h index e27ed61fe..9ccc057c5 100644 --- a/src/version.h +++ b/src/version.h @@ -1 +1 @@ -#define COMPILER_VERSION "0.3.77" \ No newline at end of file +#define COMPILER_VERSION "0.3.78" \ No newline at end of file