You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Breaking change in v0.2.145 for MUSL's open64 #3264
Good spot, and yes indeed that's an unintended change - the whole point of that module is to back-fill a non-breaking API. Unfortunately, we can't shim variadic functions since they're unstable (as local functions) rust-lang/rust#44930. If that were merged we could write something like:
An earlier version of this change re-exported the LFS64 symbols with use foo as foo64 which caused two problems:
The aliased symbols are the original symbols (have the same address for example) which would be a breaking change
use will alias all matching symbols (which is a problem for e.g. stat64 which is a type and a function)
The latter of these doesn't matter for open/openat since there's no type to conflict with the function name, but the former would still be a concern.
@JohnTitor@Amanieu - I proposed for now we switch open/openat to be aliased with a use (with a comment to re-visit once c_variadics is stabilized. thoughts?
Oh, there's a 3rd problem with use-aliasing that also doesn't affect open/openat - if the arguments of an LFS64 function are themselves LFS64-ized then a use-aliased function won't accept them when it should. Doesn't change my previous conclusion, just providing completeness.
Activity
bossmc commentedon Jun 5, 2023
Good spot, and yes indeed that's an unintended change - the whole point of that module is to back-fill a non-breaking API. Unfortunately, we can't shim variadic functions since they're unstable (as local functions) rust-lang/rust#44930. If that were merged we could write something like:
An earlier version of this change re-exported the LFS64 symbols with
use foo as foo64which caused two problems:usewill alias all matching symbols (which is a problem for e.g.stat64which is a type and a function)The latter of these doesn't matter for
open/openatsince there's no type to conflict with the function name, but the former would still be a concern.@JohnTitor @Amanieu - I proposed for now we switch open/openat to be aliased with a
use(with a comment to re-visit oncec_variadicsis stabilized. thoughts?bossmc commentedon Jun 5, 2023
Oh, there's a 3rd problem with
use-aliasing that also doesn't affectopen/openat- if the arguments of an LFS64 function are themselves LFS64-ized then ause-aliased function won't accept them when it should. Doesn't change my previous conclusion, just providing completeness.Amanieu commentedon Jun 5, 2023
I agree with changing this to a use, I think this is the best way forward.
Auto merge of #3265 - bossmc:issue-3264-variadic-open(at), r=Amanieu
Amanieu commentedon Jun 6, 2023
I've yanked v0.2.145 for now since it is causing widespread breakage.
Downgrade libc crate from yanked version
Upgrade libc crate from yanked version (#3222)
fix: update from yanked `libc` 0.2.145 to 0.2.146
fix: update from yanked `libc` 0.2.145 to 0.2.146
fix: update from yanked `libc` 0.2.145 to 0.2.146
newpavlov commentedon Aug 15, 2023
I think this issue can be closed now?