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
FileTypePartialEq implementation is buggy on Unix #104900
fnmain(){
fs::create_dir("dir").unwrap();File::create("dir/file").unwrap();for e inread_dir("dir").unwrap(){let e = e.unwrap();let p = e.path();let ft1 = e.file_type().unwrap();let ft2 = p.metadata().unwrap().file_type();assert_eq!(ft1, ft2);}}
This currently fails, even though no symlinks are involved.
This is because FileType on Unix are currently compared on the totality of their contained unix st_mode, which are bitflags of the form ...YYY0XXX (in octal) where XXX is a Unix permission mode and ...YYY the actual file type. As of now, depending on how the FileType is built, XXX may be either 000 (from DirEntry::filetype) or set to the actual file permission mode (if built from fs::metadata).
Activity
krtab commentedon Nov 29, 2022
@rustbot claim
krtab commentedon Nov 29, 2022
@rustbot label: +T-libs-api + Libs-Small
rustbot commentedon Nov 29, 2022
Error: Parsing relabel command in comment failed: ...'libs-api +' | error: empty label at >| ' Libs-Smal'...
Please file an issue on GitHub at triagebot if there's a problem with this bot, or reach out on #t-infra on Zulip.
krtab commentedon Nov 29, 2022
@rustbot label: +T-libs-api +Libs-Small
rustbot commentedon Nov 29, 2022
Error: Label Libs-Small can only be set by Rust team members
Please file an issue on GitHub at triagebot if there's a problem with this bot, or reach out on #t-infra on Zulip.
krtab commentedon Nov 29, 2022
@rustbot label: +T-libs-api
Add test for regression for FileType equality
Implement masking in FileType hashing on Unix
Implement masking in FileType comparison on Unix
Rollup merge of rust-lang#104901 - krtab:filetype_compare, r=the8472
Implement masking in FileType comparison on Unix
Add test for regression for FileType equality
Implement masking in FileType hashing on Unix
Rollup merge of #104901 - krtab:filetype_compare, r=the8472