swc/crates/better_scoped_tls
2024-04-29 00:54:45 +00:00
..
src build(cargo): Update rustc to nightly-2023-11-04 (#8221) 2023-11-04 21:47:10 +00:00
Cargo.toml chore: Apply cargo autoinherit (#8902) 2024-04-29 00:54:45 +00:00
README.md feat(api/rust): Improve error messages for wrong usages of scoped thread-local variables (#3606) 2022-02-17 08:11:46 +00:00

better_scoped_tls

This crate provides an opinionated version of scoped-tls.

Scoped thread local variables created by this crate will panic with a good message on usage without .set, like

You should perform this operation in the closure passed to `set` of better_scoped_tls::tests::TESTTLS

Syntax is exactly same to the original scoped-tls.