with-thread-local
A micro crate that simplifies a bit the use of the std macro thread_local!.
extern crate regex;
use with_thread_local;
use Regex;
let user_input = "cat";
let = with_thread_local! ;
assert!;
You can also use its variant move to move variables inside the block. Though I admit I could
not write a good example:
extern crate regex;
use with_thread_local;
use Regex;
let user_input = vec!;
let output = with_thread_local! ;
assert_eq!;