Conversation
|
r? @Amanieu (rust-highfive has picked a reviewer for you, use r? to override) |
|
Also I had to ignore |
|
Unfortunately I believe this is a breaking change, which means we can't actually do this until we bump the crate version to 1.0. cc @JohnTitor |
|
I'm aware that it is a breaking change and that's not a problem for me to wait until a new major version for this to be merged. |
|
☔ The latest upstream changes (presumably #1975) made this pull request unmergeable. Please resolve the merge conflicts. |
|
I'm unsure how to find out what's wrong with sigval on emscripten... |
|
Btw, I noted (when I originally opened this PR) that the following fields may also be wroth considering turning into unions:
|
I also don't know. I'll mark this as review as a reminder that I need to take a look at this. @rustbot review
Feel free to submit another PR! |
|
This needs another rebase, feel free to just leave Regarding traits: don't add For @rustbot author |
|
@kellda CI should be set! |
|
@rustbot author, this needs a rebase |
|
Yet another inter-semester break, yet another attempt to merge this ! |
d79341b to
7afa26e
Compare
| // sigval is a struct in Rust, but a union in C: | ||
| "sigval" => "union sigval".to_string(), | ||
|
|
There was a problem hiding this comment.
This change seems to make freebsd fail, but I'm not sure why or what would be the correct thing to do
There was a problem hiding this comment.
The FreeBSD jobs are unfortunately flakey with ctest; I've tried but I can't fix the "spooky action at a distance" response to changes that seem to happen on those.
If you can get the rests of the tests passing (looks like s390x and Solaris are failing) we can hand-review the FreeBSD changes or figure something else out there.
There was a problem hiding this comment.
The Solaris tests seems to fail for similar reasons than FreeBSD, or at least similar symptoms.
I'll investigate s390x and emscripten
c5e2e67 to
c10e99f
Compare
|
@rustbot ready |
tgross35
left a comment
There was a problem hiding this comment.
Sorry this took so long, but it looks great! I have one last request for names then please rebase one last time and I'm happy to merge.
src/fuchsia/mod.rs
Outdated
| pub ifa_addr: *mut crate::sockaddr, | ||
| pub ifa_netmask: *mut crate::sockaddr, | ||
| pub ifa_ifu: *mut crate::sockaddr, // FIXME(union) This should be a union | ||
| pub ifa_ifu: __c_anonymous_ifa_ifu, |
There was a problem hiding this comment.
This should be __c_anonymous_ifaddrs_ifa_ifu (struct name + field name)
| pub union epoll_data { | ||
| pub ptr: *mut c_void, | ||
| pub fd: c_int, | ||
| pub u32: u32, | ||
| pub u64: u64, | ||
| } |
src/unix/linux_like/mod.rs
Outdated
| pub ifa_addr: *mut crate::sockaddr, | ||
| pub ifa_netmask: *mut crate::sockaddr, | ||
| pub ifa_ifu: *mut crate::sockaddr, // FIXME(union) This should be a union | ||
| pub ifa_ifu: __c_anonymous_ifa_ifu, |
There was a problem hiding this comment.
Same here, could you include the struct name plus the field name?
tgross35
left a comment
There was a problem hiding this comment.
LGTM, thank you for the persistence across the four years since this PR opened!
CI is a bit borked right now but I'll merge this soon
For #1020
Replace some types with unions now that rustc supports them.
I also found
sigevent.sigev_notify_thread_id,siginfo_t.__dataandsigaction.sa_sigactionthat I think should be unions, but I wasn't sure.