@@ -328,6 +328,7 @@ cached_control! {
328328 Key = { input. to_owned( ) } ;
329329 PostGet ( cached_val) = return Ok ( cached_val. clone( ) ) ;
330330 PostExec ( body_result) = {
331+ #[ allow( clippy:: question_mark) ]
331332 match body_result {
332333 Ok ( v) => v,
333334 Err ( e) => return Err ( e) ,
@@ -848,7 +849,7 @@ async fn test_only_cached_option_once_per_second_a() {
848849/// to return the cached result of the one call instead of all
849850/// concurrently un-cached tasks executing and writing concurrently.
850851#[ cfg( feature = "async" ) ]
851- #[ once( time = 2 , sync_writes = "default" ) ]
852+ #[ once( time = 2 , sync_writes) ]
852853async fn only_cached_once_per_second_sync_writes ( s : String ) -> Vec < String > {
853854 vec ! [ s]
854855}
@@ -910,9 +911,9 @@ fn test_cached_sync_writes_by_key() {
910911 let b = std:: thread:: spawn ( || cached_sync_writes_by_key ( "b" . to_string ( ) ) ) ;
911912 let c = std:: thread:: spawn ( || cached_sync_writes_by_key ( "c" . to_string ( ) ) ) ;
912913 let start = Instant :: now ( ) ;
913- let a = a. join ( ) . unwrap ( ) ;
914- let b = b. join ( ) . unwrap ( ) ;
915- let c = c. join ( ) . unwrap ( ) ;
914+ let _ = a. join ( ) . unwrap ( ) ;
915+ let _ = b. join ( ) . unwrap ( ) ;
916+ let _ = c. join ( ) . unwrap ( ) ;
916917 assert ! ( start. elapsed( ) < Duration :: from_secs( 2 ) ) ;
917918}
918919
@@ -942,7 +943,7 @@ async fn test_cached_sync_writes_by_key_a() {
942943}
943944
944945#[ cfg( feature = "async" ) ]
945- #[ once( sync_writes = "default" ) ]
946+ #[ once( sync_writes = true ) ]
946947async fn once_sync_writes_a ( s : & tokio:: sync:: Mutex < String > ) -> String {
947948 let mut guard = s. lock ( ) . await ;
948949 let results: String = ( * guard) . clone ( ) . to_string ( ) ;
0 commit comments