From 25d416aca1a2b3d75cbd5ff2a6b32a12a07dfac2 Mon Sep 17 00:00:00 2001 From: Christoffer Lerno Date: Mon, 7 Apr 2025 21:58:21 +0200 Subject: [PATCH] Regression with invalid setup of the WASM temp allocator. --- lib/std/core/mem_allocator.c3 | 2 +- releasenotes.md | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/std/core/mem_allocator.c3 b/lib/std/core/mem_allocator.c3 index 4782dc04f..35dcffac9 100644 --- a/lib/std/core/mem_allocator.c3 +++ b/lib/std/core/mem_allocator.c3 @@ -435,7 +435,7 @@ fn Allocator create_temp_allocator_on_demand() @private auto_create_temp = true; abort("Use '@pool_init()' to enable the temp allocator on a new thread. A temp allocator is only implicitly created on the main thread."); } - return create_temp_allocator(base_allocator(), temp_allocator_size()); + return create_temp_allocator(temp_base_allocator, temp_allocator_size()); } <* @require !top_temp : "This should never be called when temp already exists" diff --git a/releasenotes.md b/releasenotes.md index fd24298f8..80b3aa744 100644 --- a/releasenotes.md +++ b/releasenotes.md @@ -11,6 +11,7 @@ ### Fixes - Trying to cast an enum to int and back caused the compiler to crash. - Incorrect rounding at compile time going from double to int. +- Regression with invalid setup of the WASM temp allocator. ### Stdlib changes - Hash functions for integer vectors and arrays.