-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
native: Skip non-utf16 filename on Windows #13338
Conversation
This fixes `glob::test::test_lots_of_files` test on my machine: it entered `C:\$Recycle.Bin\` and there were some system files with non-utf16 names.
Can you give me an example of one of the names? I have a long-standing issue on my plate to reinvestigate filepaths on Windows due to rumors of non-utf16 names, but I don't have any concrete data on this. Was it some sort of UCS2 name that's invalid UTF-16, or does Windows genuinely let you have names that aren't Unicode at all? |
I (on win8) succeeded to create files with strange names: |
@klutzy Ok thanks, that sounds like it's still valid UCS2, just not UTF-16. So it's not a big surprise. Still, it is a reason why WindowsPath may need to move to using |
Interesting! I would also like to add a test for this to ensure that this doesn't crop up again. I'm also a little worried how librustuv handles this case. I don't think that from rust you can easily create a non-utf16 filename, but you should be able to add a |
Closing due to inactivity, but feel free to reopen with a rebase! |
Prioritize restart messages in flycheck cc rust-lang/rust-analyzer#12936 (comment)
…, r=Centri3 fix incorrect suggestion for `!(a >= b) as i32 == c` fixes rust-lang#12761 The expression `!(a >= b) as i32 == c` got simplified to `a < b as i32 == c`, but this is a syntax error. The result we want is `(a < b) as i32 == c`. This is fixed by adding a parenthesis to the suggestion given in `check_simplify_not` when the boolean expression is casted. changelog: [`nonminimal_bool`]: fix incorrect suggestion for `!(a >= b) as i32 == c`
This fixes
glob::test::test_lots_of_files
test on my machine:it entered
C:\$Recycle.Bin\
and there were some system files withnon-utf16 names.