From e258762fa1de22336f19005e5b46783bf2a563bc Mon Sep 17 00:00:00 2001 From: Greg Burri Date: Sat, 26 Oct 2024 19:58:42 +0200 Subject: [PATCH] Exercise 07-13 and 07-14 --- exercises/07_threads/13_without_channels/tests/check.rs | 2 +- exercises/07_threads/14_sync/src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/exercises/07_threads/13_without_channels/tests/check.rs b/exercises/07_threads/13_without_channels/tests/check.rs index e0d9c88..a915761 100644 --- a/exercises/07_threads/13_without_channels/tests/check.rs +++ b/exercises/07_threads/13_without_channels/tests/check.rs @@ -7,7 +7,7 @@ use without_channels::store::TicketStore; #[test] fn works() { - let store = todo!(); + let store = Arc::new(RwLock::new(TicketStore::new())); let store1 = store.clone(); let client1 = spawn(move || { diff --git a/exercises/07_threads/14_sync/src/lib.rs b/exercises/07_threads/14_sync/src/lib.rs index c67d0f7..b698498 100644 --- a/exercises/07_threads/14_sync/src/lib.rs +++ b/exercises/07_threads/14_sync/src/lib.rs @@ -1,6 +1,6 @@ // Not much to be exercised on `Sync`, just a thing to remember. fn outro() -> &'static str { - "I have a good understanding of __!" + "I have a good understanding of Send and Sync!" } #[cfg(test)] -- 2.45.2