@@ -19,41 +19,42 @@ pub use self::signal::{SA_NODEFER, SA_NOCLDWAIT, SA_SIGINFO, SIGCHLD};
19
19
20
20
use libc;
21
21
22
- #[ cfg( target_os = "macos" ) ]
23
- # [ cfg ( target_os = "ios" ) ]
24
- # [ cfg ( target_os = "freebsd" ) ]
25
- # [ cfg ( target_os = "dragonfly" ) ]
22
+ #[ cfg( any ( target_os = "macos" ,
23
+ target_os = "ios" ,
24
+ target_os = "freebsd" ,
25
+ target_os = "dragonfly" ) ) ]
26
26
pub static FIONBIO : libc:: c_ulong = 0x8004667e ;
27
- #[ cfg( target_os = "linux" , target_arch = "x86" ) ]
28
- #[ cfg( target_os = "linux" , target_arch = "x86_64" ) ]
29
- #[ cfg( target_os = "linux" , target_arch = "arm" ) ]
30
- #[ cfg( target_os = "android" ) ]
27
+ #[ cfg( any( all( target_os = "linux" ,
28
+ any( target_arch = "x86" ,
29
+ target_arch = "x86_64" ,
30
+ target_arch = "arm" ) ) ,
31
+ target_os = "android" ) ) ]
31
32
pub static FIONBIO : libc:: c_ulong = 0x5421 ;
32
- #[ cfg( target_os = "linux" , target_arch = "mips" ) ]
33
- # [ cfg ( target_os = "linux " , target_arch = "mipsel" ) ]
33
+ #[ cfg( all ( target_os = "linux" ,
34
+ any ( target_arch = "mips " , target_arch = "mipsel" ) ) ) ]
34
35
pub static FIONBIO : libc:: c_ulong = 0x667e ;
35
36
36
- #[ cfg( target_os = "macos" ) ]
37
- # [ cfg ( target_os = "ios" ) ]
38
- # [ cfg ( target_os = "freebsd" ) ]
39
- # [ cfg ( target_os = "dragonfly" ) ]
37
+ #[ cfg( any ( target_os = "macos" ,
38
+ target_os = "ios" ,
39
+ target_os = "freebsd" ,
40
+ target_os = "dragonfly" ) ) ]
40
41
pub static FIOCLEX : libc:: c_ulong = 0x20006601 ;
41
- #[ cfg( target_os = "linux" , target_arch = "x86" ) ]
42
- #[ cfg( target_os = "linux" , target_arch = "x86_64" ) ]
43
- #[ cfg( target_os = "linux" , target_arch = "arm" ) ]
44
- #[ cfg( target_os = "android" ) ]
42
+ #[ cfg( any( all( target_os = "linux" ,
43
+ any( target_arch = "x86" ,
44
+ target_arch = "x86_64" ,
45
+ target_arch = "arm" ) ) ,
46
+ target_os = "android" ) ) ]
45
47
pub static FIOCLEX : libc:: c_ulong = 0x5451 ;
46
- #[ cfg( target_os = "linux" , target_arch = "mips" ) ]
47
- # [ cfg ( target_os = "linux " , target_arch = "mipsel" ) ]
48
+ #[ cfg( all ( target_os = "linux" ,
49
+ any ( target_arch = "mips " , target_arch = "mipsel" ) ) ) ]
48
50
pub static FIOCLEX : libc:: c_ulong = 0x6601 ;
49
51
50
- #[ cfg( target_os = "macos" ) ]
51
- # [ cfg ( target_os = "ios" ) ]
52
- # [ cfg ( target_os = "freebsd" ) ]
53
- # [ cfg ( target_os = "dragonfly" ) ]
52
+ #[ cfg( any ( target_os = "macos" ,
53
+ target_os = "ios" ,
54
+ target_os = "freebsd" ,
55
+ target_os = "dragonfly" ) ) ]
54
56
pub static MSG_DONTWAIT : libc:: c_int = 0x80 ;
55
- #[ cfg( target_os = "linux" ) ]
56
- #[ cfg( target_os = "android" ) ]
57
+ #[ cfg( any( target_os = "linux" , target_os = "android" ) ) ]
57
58
pub static MSG_DONTWAIT : libc:: c_int = 0x40 ;
58
59
59
60
pub static WNOHANG : libc:: c_int = 1 ;
@@ -86,8 +87,7 @@ extern {
86
87
pub fn sigemptyset ( set : * mut sigset_t ) -> libc:: c_int ;
87
88
}
88
89
89
- #[ cfg( target_os = "macos" ) ]
90
- #[ cfg( target_os = "ios" ) ]
90
+ #[ cfg( any( target_os = "macos" , target_os = "ios" ) ) ]
91
91
mod select {
92
92
pub static FD_SETSIZE : uint = 1024 ;
93
93
@@ -101,10 +101,10 @@ mod select {
101
101
}
102
102
}
103
103
104
- #[ cfg( target_os = "android" ) ]
105
- # [ cfg ( target_os = "freebsd" ) ]
106
- # [ cfg ( target_os = "dragonfly" ) ]
107
- # [ cfg ( target_os = "linux" ) ]
104
+ #[ cfg( any ( target_os = "android" ,
105
+ target_os = "freebsd" ,
106
+ target_os = "dragonfly" ,
107
+ target_os = "linux" ) ) ]
108
108
mod select {
109
109
use std:: uint;
110
110
use libc;
@@ -123,10 +123,11 @@ mod select {
123
123
}
124
124
}
125
125
126
- #[ cfg( target_os = "linux" , target_arch = "x86" ) ]
127
- #[ cfg( target_os = "linux" , target_arch = "x86_64" ) ]
128
- #[ cfg( target_os = "linux" , target_arch = "arm" ) ]
129
- #[ cfg( target_os = "android" ) ]
126
+ #[ cfg( any( all( target_os = "linux" ,
127
+ any( target_arch = "x86" ,
128
+ target_arch = "x86_64" ,
129
+ target_arch = "arm" ) ) ,
130
+ target_os = "android" ) ) ]
130
131
mod signal {
131
132
use libc;
132
133
@@ -173,8 +174,8 @@ mod signal {
173
174
}
174
175
}
175
176
176
- #[ cfg( target_os = "linux" , target_arch = "mips" ) ]
177
- # [ cfg ( target_os = "linux " , target_arch = "mipsel" ) ]
177
+ #[ cfg( all ( target_os = "linux" ,
178
+ any ( target_arch = "mips " , target_arch = "mipsel" ) ) ) ]
178
179
mod signal {
179
180
use libc;
180
181
@@ -215,10 +216,10 @@ mod signal {
215
216
}
216
217
}
217
218
218
- #[ cfg( target_os = "macos" ) ]
219
- # [ cfg ( target_os = "ios" ) ]
220
- # [ cfg ( target_os = "freebsd" ) ]
221
- # [ cfg ( target_os = "dragonfly" ) ]
219
+ #[ cfg( any ( target_os = "macos" ,
220
+ target_os = "ios" ,
221
+ target_os = "freebsd" ,
222
+ target_os = "dragonfly" ) ) ]
222
223
mod signal {
223
224
use libc;
224
225
0 commit comments