]> git.lizzy.rs Git - rust.git/commit
std: Ensure OOM is classified as `nounwind`
authorAlex Crichton <alex@alexcrichton.com>
Thu, 24 May 2018 19:03:05 +0000 (12:03 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Thu, 24 May 2018 19:03:05 +0000 (12:03 -0700)
commitf67453729c19b435686c94936d8145051e7f1284
tree029525400c5744b7251bfaa55b8f04a6449bd5ee
parenta76bff86e6f4b56b2c3fd1704ce8535ed207dd78
std: Ensure OOM is classified as `nounwind`

OOM can't unwind today, and historically it's been optimized as if it can't
unwind. This accidentally regressed with recent changes to the OOM handler, so
this commit adds in a codegen test to assert that everything gets optimized away
after the OOM function is approrpiately classified as nounwind

Closes #50925
src/liballoc/alloc.rs
src/librustc_codegen_llvm/attributes.rs
src/librustc_codegen_llvm/callee.rs
src/test/codegen/vec-iter-collect-len.rs [new file with mode: 0644]