Skip to content

Commit f4fd177

Browse files
committed
chore(router): Allow unreachable patterns
1 parent 8d6d46b commit f4fd177

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tonic/src/service/router.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,9 @@ impl Future for RoutesFuture {
162162
fn poll(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output> {
163163
match ready!(Pin::new(&mut self.as_mut().0).poll(cx)) {
164164
Ok(res) => Ok(res.map(boxed)).into(),
165+
// NOTE: This pattern is not needed from Rust 1.82.
166+
// See https://github.com/rust-lang/rust/pull/122792.
167+
#[allow(unreachable_patterns)]
165168
Err(err) => match err {},
166169
}
167170
}

0 commit comments

Comments
 (0)