File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Expand file tree Collapse file tree 1 file changed +12
-4
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;
@@ -593,11 +594,9 @@ impl From<Signal> for SigSet {
593
594
}
594
595
}
595
596
596
-
597
- impl std:: ops:: BitOr for Signal {
597
+ impl BitOr for Signal {
598
598
type Output = SigSet ;
599
599
600
- // rhs is the "right-hand side" of the expression `a | b`
601
600
fn bitor( self , rhs: Self ) -> Self :: Output {
602
601
let mut sigset = SigSet :: empty( ) ;
603
602
sigset. add( self ) ;
@@ -606,7 +605,16 @@ impl std::ops::BitOr for Signal {
606
605
}
607
606
}
608
607
609
- impl std:: ops:: BitOr for SigSet {
608
+ impl BitOr <Signal > for SigSet {
609
+ type Output = SigSet ;
610
+
611
+ fn bitor( mut self , rhs: Signal ) -> Self :: Output {
612
+ self . add( rhs) ;
613
+ self
614
+ }
615
+ }
616
+
617
+ impl BitOr for SigSet {
610
618
type Output = Self ;
611
619
612
620
fn bitor( self , rhs: Self ) -> Self :: Output {
You can’t perform that action at this time.
0 commit comments