@@ -1098,8 +1098,6 @@ fn test_solarish(target: &str) {
1098
1098
1099
1099
cfg. field_name ( move |struct_, field| {
1100
1100
match struct_ {
1101
- // rust struct uses raw u64, rather than union
1102
- "epoll_event" if field == "u64" => "data.u64" . to_string ( ) ,
1103
1101
// rust struct was committed with typo for Solaris
1104
1102
"door_arg_t" if field == "dec_num" => "desc_num" . to_string ( ) ,
1105
1103
"stat" if field. ends_with ( "_nsec" ) => {
@@ -1372,7 +1370,6 @@ fn test_netbsd(target: &str) {
1372
1370
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => {
1373
1371
s. replace ( "e_nsec" , ".tv_nsec" )
1374
1372
}
1375
- "u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
1376
1373
s => s. to_string ( ) ,
1377
1374
}
1378
1375
} ) ;
@@ -1583,7 +1580,6 @@ fn test_dragonflybsd(target: &str) {
1583
1580
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => {
1584
1581
s. replace ( "e_nsec" , ".tv_nsec" )
1585
1582
}
1586
- "u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
1587
1583
// Field is named `type` in C but that is a Rust keyword,
1588
1584
// so these fields are translated to `type_` in the bindings.
1589
1585
"type_" if struct_ == "rtprio" => "type" . to_string ( ) ,
@@ -1965,8 +1961,6 @@ fn test_android(target: &str) {
1965
1961
// Our stat *_nsec fields normally don't actually exist but are part
1966
1962
// of a timeval struct
1967
1963
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => s. to_string ( ) ,
1968
- // FIXME(union): appears that `epoll_event.data` is an union
1969
- "u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
1970
1964
// The following structs have a field called `type` in C,
1971
1965
// but `type` is a Rust keyword, so these fields are translated
1972
1966
// to `type_` in Rust.
@@ -3063,8 +3057,6 @@ fn test_emscripten(target: &str) {
3063
3057
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => {
3064
3058
s. replace ( "e_nsec" , ".tv_nsec" )
3065
3059
}
3066
- // Rust struct uses raw u64, rather than union
3067
- "u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
3068
3060
s => s. to_string ( ) ,
3069
3061
}
3070
3062
} ) ;
@@ -3873,10 +3865,6 @@ fn test_linux(target: &str) {
3873
3865
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => {
3874
3866
s. replace ( "e_nsec" , ".tv_nsec" )
3875
3867
}
3876
- // FIXME(linux): epoll_event.data is actually a union in C, but in Rust
3877
- // it is only a u64 because we only expose one field
3878
- // http://man7.org/linux/man-pages/man2/epoll_wait.2.html
3879
- "u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
3880
3868
// The following structs have a field called `type` in C,
3881
3869
// but `type` is a Rust keyword, so these fields are translated
3882
3870
// to `type_` in Rust.
0 commit comments