Do not auto-deref subscripting.

This commit is contained in:
Christoffer Lerno
2022-12-15 23:36:52 +01:00
committed by Christoffer Lerno
parent 10219eccb2
commit 8008fb2c18
6 changed files with 69 additions and 68 deletions

View File

@@ -301,7 +301,7 @@ static void linker_setup_macos(const char ***args_ref, LinkerType linker_type)
if (is_pie(platform_target.reloc_model)) add_arg("-pie");
add_arg("-platform_version");
add_arg("macos");
add_arg(str_printf("%d.0.0", mac_sdk->macos_deploy_target.major));
add_arg(str_printf("%d.%d.0", mac_sdk->macos_min_deploy_target.major, mac_sdk->macos_min_deploy_target.minor));
add_arg(str_printf("%d.%d", mac_sdk->macos_deploy_target.major, mac_sdk->macos_deploy_target.minor));
}

View File

@@ -2278,7 +2278,6 @@ static inline bool sema_expr_analyse_subscript(SemaContext *context, Expr *expr,
// 1. Evaluate the expression to index.
Expr *subscripted = exprptr(expr->subscript_expr.expr);
if (!sema_analyse_expr_lvalue_fold_const(context, subscripted)) return false;
sema_subscript_deref_array_pointers(subscripted);
// 2. Evaluate the index.
Expr *index = exprptr(expr->subscript_expr.range.start);

View File

@@ -1 +1 @@
#define COMPILER_VERSION "0.3.120"
#define COMPILER_VERSION "0.3.121"