From 8d1922d4c80335d7c850e5856ae0ec549b8a0481 Mon Sep 17 00:00:00 2001 From: Eric Holk Date: Mon, 6 Aug 2012 18:29:05 -0700 Subject: [PATCH] Add a selectable implementation for *packet_header --- src/libcore/pipes.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libcore/pipes.rs b/src/libcore/pipes.rs index 33ee3cc52fb..e56bb456189 100644 --- a/src/libcore/pipes.rs +++ b/src/libcore/pipes.rs @@ -624,6 +624,10 @@ trait selectable { pure fn header() -> *packet_header; } +impl of selectable for *packet_header { + pure fn header() -> *packet_header { self } +} + /// Returns the index of an endpoint that is ready to receive. fn selecti(endpoints: &[T]) -> uint { wait_many(endpoints.map(|p| p.header()))