Cargo Features
[dependencies]
zng-app-context = { version = "0.5.12", default-features = false, features = ["multi_app", "debug_default", "dyn_closure"] }
- default = debug_default
-
The
debug_default
feature is set by default wheneverzng-app-context
is added without
somewhere in the dependency tree.default-features = false - multi_app
-
Allows multiple app instances per-process.
This feature allows multiple apps, one app per thread at a time. The
LocalContext
tracks what app is currently running in each thread andapp_local!
statics switch to the value of each app depending on the current thread. - debug_default default
-
Enable
"multi_app"
in debug builds. - dyn_closure
-
Box closures at opportune places, such as
Var::map
, reducing the number of monomorphised types.This speeds-up compilation time at the cost of runtime.