Skip to content
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

Rollup of 5 pull requests #99400

Closed
wants to merge 13 commits into from
Closed

Commits on Jul 3, 2022

  1. Configuration menu
    Copy the full SHA
    5f5ca88 View commit details
    Browse the repository at this point in the history

Commits on Jul 5, 2022

  1. Configuration menu
    Copy the full SHA
    13ab796 View commit details
    Browse the repository at this point in the history
  2. Windows: Use FindFirstFileW if metadata fails

    Usually opening a file handle with access set to metadata only will always succeed, even if the file is locked. However some special system files, such as `C:\hiberfil.sys`, are locked by the system in a way that denies even that. So as a fallback we try reading the cached metadata from the directory.
    ChrisDenton committed Jul 5, 2022
    Configuration menu
    Copy the full SHA
    8d4adad View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    2d06504 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    5f5bcb3 View commit details
    Browse the repository at this point in the history

Commits on Jul 12, 2022

  1. Add test for rust-lang#96797

    This was fixed in LLVM which was updated in rust-lang#98285.
    
    https://reviews.llvm.org/D127751
    
    Fixes rust-lang#96797
    Amanieu committed Jul 12, 2022
    Configuration menu
    Copy the full SHA
    5566099 View commit details
    Browse the repository at this point in the history

Commits on Jul 14, 2022

  1. Configuration menu
    Copy the full SHA
    080a53a View commit details
    Browse the repository at this point in the history

Commits on Jul 18, 2022

  1. Add regression test for rust-lang#95230

    Signed-off-by: Yuki Okushi <jtitor@2k36.org>
    JohnTitor committed Jul 18, 2022
    Configuration menu
    Copy the full SHA
    5172a2f View commit details
    Browse the repository at this point in the history
  2. Rollup merge of rust-lang#98839 - 5225225:assert_transmute_copy_size,…

    … r=thomcc
    
    Add assertion that `transmute_copy`'s U is not larger than T
    
    This is called out as a safety requirement in the docs, but because knowing this can be done at compile time and constant folded (just like the `align_of` branch is removed), we can just panic here.
    
    I've looked at the asm (using `cargo-asm`) of a function that both is correct and incorrect, and the panic is completely removed, or is unconditional, without needing build-std.
    
    I don't expect this to cause much breakage in the wild. I scanned through https://miri.saethlin.dev/ub for issues that would look like this (error: Undefined Behavior: memory access failed: alloc1768 has size 1, so pointer to 8 bytes starting at offset 0 is out-of-bounds), but couldn't find any.
    
    That doesn't rule out it happening in crates tested that fail earlier for some other reason, though, but it indicates that doing this is rare, if it happens at all. A crater run for this would need to be build and test, since this is a runtime thing.
    
    Also added a few more transmute_copy tests.
    Dylan-DPC authored Jul 18, 2022
    Configuration menu
    Copy the full SHA
    9b6e006 View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#98916 - ChrisDenton:hiberfil.sys, r=thomcc

    Windows: Use `FindFirstFileW` for getting the metadata of locked system files
    
    Fixes rust-lang#96980
    
    Usually opening a file handle with access set to metadata only will always succeed, even if the file is locked. However some special system files, such as `C:\hiberfil.sys`, are locked by the system in a way that denies even that. So as a fallback we try reading the cached metadata from the directory.
    
    Note that the test is a bit iffy. I don't know if `hiberfil.sys` actually exists in the CI.
    
    r? rust-lang/libs
    Dylan-DPC authored Jul 18, 2022
    Configuration menu
    Copy the full SHA
    03f81bf View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    5e58b1b View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#99198 - RalfJung:alloc-null-ptr, r=JohnTitor

    add missing null ptr check in alloc example
    
    `alloc` can return null on OOM, if I understood correctly. So we should never just deref a pointer we get from `alloc`.
    Dylan-DPC authored Jul 18, 2022
    Configuration menu
    Copy the full SHA
    3bee5a1 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#99394 - JohnTitor:issue-95230, r=compiler-e…

    …rrors
    
    Add regression test for rust-lang#95230
    
    Closes rust-lang#95230
    r? ``@compiler-errors``
    
    Signed-off-by: Yuki Okushi <jtitor@2k36.org>
    Dylan-DPC authored Jul 18, 2022
    Configuration menu
    Copy the full SHA
    86c049f View commit details
    Browse the repository at this point in the history