File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ use crate::{Error, Result};
8
8
use cfg_if:: cfg_if;
9
9
use std:: fmt;
10
10
use std:: mem;
11
+ use std:: ops:: BitOr ;
11
12
#[ cfg( any( target_os = "dragonfly" , target_os = "freebsd" ) ) ]
12
13
use std:: os:: unix:: io:: RawFd ;
13
14
use std:: ptr;
@@ -594,10 +595,9 @@ impl From<Signal> for SigSet {
594
595
}
595
596
596
597
597
- impl std :: ops :: BitOr for Signal {
598
+ impl BitOr for Signal {
598
599
type Output = SigSet ;
599
600
600
- // rhs is the "right-hand side" of the expression `a | b`
601
601
fn bitor( self , rhs: Self ) -> Self :: Output {
602
602
let mut sigset = SigSet :: empty( ) ;
603
603
sigset. add( self ) ;
@@ -606,7 +606,16 @@ impl std::ops::BitOr for Signal {
606
606
}
607
607
}
608
608
609
- impl std:: ops:: BitOr for SigSet {
609
+ impl BitOr <Signal > for SigSet {
610
+ type Output = SigSet ;
611
+
612
+ fn bitor( mut self , rhs: Signal ) -> Self :: Output {
613
+ self . add( rhs) ;
614
+ self
615
+ }
616
+ }
617
+
618
+ impl BitOr for SigSet {
610
619
type Output = Self ;
611
620
612
621
fn bitor( self , rhs: Self ) -> Self :: Output {
You can’t perform that action at this time.
0 commit comments