Use no-std-compat to build no-std.
This commit is contained in:
@@ -41,7 +41,7 @@ internals = [] # expose internal data structures
|
||||
unicode-xid-ident = ["unicode-xid"] # allow Unicode Standard Annex #31 for identifiers.
|
||||
metadata = ["serde_json", "rhai_codegen/metadata"] # enable exporting functions metadata
|
||||
|
||||
no_std = ["num-traits/libm", "core-error", "libm", "ahash/compile-time-rng"]
|
||||
no_std = ["no-std-compat", "num-traits/libm", "core-error", "libm", "ahash/compile-time-rng"]
|
||||
|
||||
# compiling for WASM
|
||||
wasm-bindgen = ["instant/wasm-bindgen"]
|
||||
@@ -53,6 +53,12 @@ codegen-units = 1
|
||||
#opt-level = "z" # optimize for size
|
||||
#panic = 'abort' # remove stack backtrace for no-std
|
||||
|
||||
[dependencies.no-std-compat]
|
||||
version = "0.4"
|
||||
default_features = false
|
||||
features = ["alloc"]
|
||||
optional = true
|
||||
|
||||
[dependencies.libm]
|
||||
version = "0.2"
|
||||
default_features = false
|
||||
|
Reference in New Issue
Block a user