@@ -974,7 +974,7 @@ pub trait IpLayerIngressContext<
974974 I : IpLayerIpExt + IcmpHandlerIpExt ,
975975 BC : IpLayerBindingsContext < I , Self :: DeviceId > ,
976976> :
977- IpTransportDispatchContext < I , BC , DeviceId = Self :: DeviceId_ >
977+ IpTransportDispatchContext < I , BC , DeviceId : filter :: InterfaceProperties < BC :: DeviceClass > >
978978 + IpDeviceStateContext < I , BC >
979979 + IpDeviceSendContext < I , BC >
980980 + IcmpErrorHandler < I , BC >
@@ -983,57 +983,43 @@ pub trait IpLayerIngressContext<
983983 + FilterHandlerProvider < I , BC >
984984 + RawIpSocketHandler < I , BC >
985985{
986- // This is working around the fact that currently, where clauses are only
987- // elaborated for supertraits, and not, for example, bounds on associated types
988- // as we have here.
989- //
990- // See https://github.com/rust-lang/rust/issues/20671#issuecomment-1905186183
991- // for more discussion.
992- type DeviceId_ : filter:: InterfaceProperties < BC :: DeviceClass > + Debug ;
993986}
994987
995988impl <
996989 I : IpLayerIpExt + IcmpHandlerIpExt ,
997990 BC : IpLayerBindingsContext < I , CC :: DeviceId > ,
998- CC : IpTransportDispatchContext < I , BC >
999- + IpDeviceStateContext < I , BC >
991+ CC : IpTransportDispatchContext <
992+ I ,
993+ BC ,
994+ DeviceId : filter:: InterfaceProperties < BC :: DeviceClass > ,
995+ > + IpDeviceStateContext < I , BC >
1000996 + IpDeviceSendContext < I , BC >
1001997 + IcmpErrorHandler < I , BC >
1002998 + IpLayerContext < I , BC >
1003999 + FragmentHandler < I , BC >
10041000 + FilterHandlerProvider < I , BC >
10051001 + RawIpSocketHandler < I , BC > ,
10061002 > IpLayerIngressContext < I , BC > for CC
1007- where
1008- Self :: DeviceId : filter:: InterfaceProperties < BC :: DeviceClass > ,
10091003{
1010- type DeviceId_ = Self :: DeviceId ;
10111004}
10121005
10131006/// A marker trait for all the contexts required for IP egress.
10141007pub ( crate ) trait IpLayerEgressContext < I , BC > :
1015- IpDeviceSendContext < I , BC , DeviceId = Self :: DeviceId_ > + FilterHandlerProvider < I , BC >
1008+ IpDeviceSendContext < I , BC , DeviceId : filter:: InterfaceProperties < BC :: DeviceClass > >
1009+ + FilterHandlerProvider < I , BC >
10161010where
10171011 I : IpLayerIpExt ,
10181012 BC : FilterBindingsContext ,
10191013{
1020- // This is working around the fact that currently, where clauses are only
1021- // elaborated for supertraits, and not, for example, bounds on associated types
1022- // as we have here.
1023- //
1024- // See https://github.com/rust-lang/rust/issues/20671#issuecomment-1905186183
1025- // for more discussion.
1026- type DeviceId_ : filter:: InterfaceProperties < BC :: DeviceClass > + StrongDeviceIdentifier + Debug ;
10271014}
10281015
10291016impl < I , BC , CC > IpLayerEgressContext < I , BC > for CC
10301017where
10311018 I : IpLayerIpExt ,
10321019 BC : FilterBindingsContext ,
1033- CC : IpDeviceSendContext < I , BC > + FilterHandlerProvider < I , BC > ,
1034- Self :: DeviceId : filter :: InterfaceProperties < BC :: DeviceClass > ,
1020+ CC : IpDeviceSendContext < I , BC , DeviceId : filter :: InterfaceProperties < BC :: DeviceClass > >
1021+ + FilterHandlerProvider < I , BC > ,
10351022{
1036- type DeviceId_ = Self :: DeviceId ;
10371023}
10381024
10391025/// A builder for IPv4 state.
0 commit comments