File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ use futures::Stream;
5
5
/// inner module, used to group feature-specific imports
6
6
#[ cfg( async_channel_impl = "tokio" ) ]
7
7
mod inner {
8
- pub use tokio:: sync:: mpsc:: error:: { SendError , TryRecvError } ;
8
+ pub use tokio:: sync:: mpsc:: error:: { SendError , TryRecvError , TrySendError } ;
9
9
10
10
use tokio:: sync:: mpsc:: { Receiver as InnerReceiver , Sender as InnerSender } ;
11
11
@@ -128,12 +128,7 @@ impl<T> Sender<T> {
128
128
/// - If the channel is full
129
129
/// - If the channel is dropped
130
130
pub fn try_send ( & self , msg : T ) -> Result < ( ) , TrySendError < T > > {
131
- #[ cfg( async_channel_impl = "flume" ) ]
132
- let result = self . 0 . try_send ( msg) ;
133
- #[ cfg( not( all( async_channel_impl = "flume" ) ) ) ]
134
- let result = self . 0 . try_send ( msg) ;
135
-
136
- result
131
+ self . 0 . try_send ( msg)
137
132
}
138
133
}
139
134
You can’t perform that action at this time.
0 commit comments