Skip to content

Commit bd063df

Browse files
bors[bot]tsoutsman
andauthored
Merge #679
679: Remove implicit sized bound on device generics r=Dirbaio a=tsoutsman The generic is only ever accessed through a reference and so it doesn't have to be sized. Signed-off-by: Klim Tsoutsman <klim@tsoutsman.com> Co-authored-by: Klim Tsoutsman <klim@tsoutsman.com>
2 parents 6b8b667 + 2a302ff commit bd063df

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/iface/interface.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ let iface = builder.finalize(&mut device);
429429
/// [neighbor_cache]: #method.neighbor_cache
430430
pub fn finalize<D>(self, device: &mut D) -> Interface<'a>
431431
where
432-
D: for<'d> Device<'d>,
432+
D: for<'d> Device<'d> + ?Sized,
433433
{
434434
let caps = device.capabilities();
435435

@@ -764,7 +764,7 @@ impl<'a> Interface<'a> {
764764
timestamp: Instant,
765765
) -> Result<bool>
766766
where
767-
D: for<'d> Device<'d>,
767+
D: for<'d> Device<'d> + ?Sized,
768768
{
769769
self.inner.now = timestamp;
770770

@@ -806,7 +806,7 @@ impl<'a> Interface<'a> {
806806
timestamp: Instant,
807807
) -> Result<bool>
808808
where
809-
D: for<'d> Device<'d>,
809+
D: for<'d> Device<'d> + ?Sized,
810810
{
811811
self.inner.now = timestamp;
812812

@@ -906,7 +906,7 @@ impl<'a> Interface<'a> {
906906
sockets: &mut SocketSet<'_>,
907907
) -> Result<bool>
908908
where
909-
D: for<'d> Device<'d>,
909+
D: for<'d> Device<'d> + ?Sized,
910910
{
911911
self.inner.now = timestamp;
912912

@@ -1006,7 +1006,7 @@ impl<'a> Interface<'a> {
10061006

10071007
fn socket_ingress<D>(&mut self, device: &mut D, sockets: &mut SocketSet<'_>) -> bool
10081008
where
1009-
D: for<'d> Device<'d>,
1009+
D: for<'d> Device<'d> + ?Sized,
10101010
{
10111011
let mut processed_any = false;
10121012
let Self {
@@ -1060,7 +1060,7 @@ impl<'a> Interface<'a> {
10601060

10611061
fn socket_egress<D>(&mut self, device: &mut D, sockets: &mut SocketSet<'_>) -> bool
10621062
where
1063-
D: for<'d> Device<'d>,
1063+
D: for<'d> Device<'d> + ?Sized,
10641064
{
10651065
let Self {
10661066
inner,
@@ -1172,7 +1172,7 @@ impl<'a> Interface<'a> {
11721172
#[cfg(feature = "proto-igmp")]
11731173
fn igmp_egress<D>(&mut self, device: &mut D) -> Result<bool>
11741174
where
1175-
D: for<'d> Device<'d>,
1175+
D: for<'d> Device<'d> + ?Sized,
11761176
{
11771177
match self.inner.igmp_report_state {
11781178
IgmpReportState::ToSpecificQuery {
@@ -1233,7 +1233,7 @@ impl<'a> Interface<'a> {
12331233
#[cfg(feature = "proto-sixlowpan-fragmentation")]
12341234
fn sixlowpan_egress<D>(&mut self, device: &mut D) -> Result<bool>
12351235
where
1236-
D: for<'d> Device<'d>,
1236+
D: for<'d> Device<'d> + ?Sized,
12371237
{
12381238
let SixlowpanOutPacket {
12391239
packet_len,

0 commit comments

Comments
 (0)