Remove one level of indirection for Context::name.
This changes the type of Context
's name
field from Arc<RwLock<Box<str>>
to Cow<'static, str>
. The name field was originally defined as an Arc as it was copied between clones, which no longer is the case. It would be even better to make context names fixed size, using either the arrayvec
or string
crates, and limit the size to e.g. 16 (Linux's size for thread names) or 32 bytes.
The kmain contexts are now also named as such.