diff --git a/tower/src/lib.rs b/tower/src/lib.rs index e969727..b86aaa0 100644 --- a/tower/src/lib.rs +++ b/tower/src/lib.rs @@ -8,7 +8,7 @@ trait TryStream: Stream { impl TryStream for S where - S: ?Sized + Stream, + S: Stream, { type TryItem = T; } @@ -56,22 +56,14 @@ impl Stream for MS where MS: MakeService, { - type Item = SvcWrap; + type Item = MS::Service; } -pub fn broken() +pub fn broken(ms: MS) where MS: MakeService, MS::Error: Into<()>, { - let d: MS = todo!(); - // Error: Apparently Balance::new doesn't exist during MIR validation - let _ = Balance::new(d); -} - -struct SvcWrap(Svc); - -impl> Service for SvcWrap { - type Error = Svc::Error; + let _ = Balance::::new(ms); }