mirror of
https://github.com/TecharoHQ/anubis.git
synced 2026-04-23 08:36:41 +00:00
fix(wasm): use wee_alloc instead of stdlib malloc
Signed-off-by: Xe Iaso <me@xeiaso.net>
This commit is contained in:
@@ -4,3 +4,4 @@ version = "0.1.0"
|
||||
edition = "2024"
|
||||
|
||||
[dependencies]
|
||||
wee_alloc = "0.4"
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
use std::sync::{LazyLock, Mutex};
|
||||
|
||||
extern crate wee_alloc;
|
||||
|
||||
#[global_allocator]
|
||||
static ALLOC: wee_alloc::WeeAlloc = wee_alloc::WeeAlloc::INIT;
|
||||
|
||||
#[cfg(target_arch = "wasm32")]
|
||||
mod hostimport {
|
||||
use crate::{DATA_BUFFER, DATA_LENGTH};
|
||||
|
||||
Reference in New Issue
Block a user