Skip to content

Commit 159cf95

Browse files
committed
Auto merge of #7 - japaric:gh5, r=japaric
fix warning in block! when the error type is ! closes #5
2 parents ecf68c7 + caac615 commit 159cf95

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -328,8 +328,12 @@ macro_rules! await {
328328
macro_rules! block {
329329
($e:expr) => {
330330
loop {
331+
#[allow(unreachable_patterns)]
331332
match $e {
332-
Err($crate::Error::Other(e)) => break Err(e),
333+
Err($crate::Error::Other(e)) => {
334+
#[allow(unreachable_code)]
335+
break Err(e)
336+
},
333337
Err($crate::Error::WouldBlock) => {},
334338
Ok(x) => break Ok(x),
335339
}

0 commit comments

Comments
 (0)