Add lock_update function for safer multithreading

&v = (v, 1).sum might fail if two threads do it at the same time or something, so you can now lock the reference to ensure no other thread messes with your data while you update its value
This commit is contained in:
Mark
2023-11-10 13:18:34 +01:00
parent 68d5b55c6f
commit 8bdd6e00e8
8 changed files with 67 additions and 20 deletions

View File

@@ -92,8 +92,6 @@ fn main() {
std::process::exit(36);
}
};
#[cfg(debug_assertions)]
dbg!(&return_type);
if args.check == Check::Yes {
run.run(&mut info_run);
} else {