Skip to content

Commit

Permalink
Allow handle_alloc_error to unwind
Browse files Browse the repository at this point in the history
  • Loading branch information
Amanieu committed Feb 5, 2022
1 parent 291bf94 commit b1b8810
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions library/alloc/src/alloc.rs
Expand Up @@ -348,7 +348,6 @@ extern "Rust" {
// This is the magic symbol to call the global alloc error handler. rustc generates
// it to call `__rg_oom` if there is a `#[alloc_error_handler]`, or to call the
// default implementations below (`__rdl_oom`) otherwise.
#[rustc_allocator_nounwind]
fn __rust_alloc_error_handler(size: usize, align: usize) -> !;
}

Expand All @@ -367,7 +366,6 @@ extern "Rust" {
#[stable(feature = "global_alloc", since = "1.28.0")]
#[rustc_const_unstable(feature = "const_alloc_error", issue = "92523")]
#[cfg(all(not(no_global_oom_handling), not(test)))]
#[rustc_allocator_nounwind]
#[cold]
pub const fn handle_alloc_error(layout: Layout) -> ! {
const fn ct_error(_: Layout) -> ! {
Expand Down

0 comments on commit b1b8810

Please sign in to comment.