Skip to main content

set_var

Function set_var 

Source
pub unsafe fn set_var(name: &str, value: &str)
Expand description

Set $name to value for this process — std::env::set_var.

§Safety

The process must be single-threaded, or no other thread may read or write the environment during the call: setenv is not thread-safe, which is why std::env::set_var is unsafe too. Its callers run in the boot funnel, before any executor or tier task exists.