diff options
| author | bjorn3 <bjorn3@users.noreply.github.com> | 2021-07-03 17:50:53 +0200 |
|---|---|---|
| committer | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2023-05-11 14:35:08 +0000 |
| commit | 6ba7c5db079132b5d85112083691d4203a6b761c (patch) | |
| tree | cf458717a8b40fb3a83bf1518807a4178a1e4f85 /compiler/rustc_codegen_llvm/src | |
| parent | 4ce20663f767c7d1610411b21ed31db3e9af21f4 (diff) | |
| download | rust-6ba7c5db079132b5d85112083691d4203a6b761c.tar.gz rust-6ba7c5db079132b5d85112083691d4203a6b761c.zip | |
Split AllocatorKind::fn_name in global_fn_name and default_fn_name
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
| -rw-r--r-- | compiler/rustc_codegen_llvm/src/allocator.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_codegen_llvm/src/allocator.rs b/compiler/rustc_codegen_llvm/src/allocator.rs index acf44f3276d..c2484681072 100644 --- a/compiler/rustc_codegen_llvm/src/allocator.rs +++ b/compiler/rustc_codegen_llvm/src/allocator.rs @@ -1,7 +1,7 @@ use crate::attributes; use libc::c_uint; use rustc_ast::expand::allocator::{ - alloc_error_handler_name, AllocatorKind, AllocatorTy, ALLOCATOR_METHODS, + alloc_error_handler_name, default_fn_name, AllocatorKind, AllocatorTy, ALLOCATOR_METHODS, }; use rustc_middle::bug; use rustc_middle::ty::TyCtxt; @@ -71,7 +71,7 @@ pub(crate) unsafe fn codegen( attributes::apply_to_llfn(llfn, llvm::AttributePlace::Function, &[uwtable]); } - let callee = AllocatorKind::Default.fn_name(method.name); + let callee = default_fn_name(method.name); let callee = llvm::LLVMRustGetOrInsertFunction(llmod, callee.as_ptr().cast(), callee.len(), ty); llvm::LLVMRustSetVisibility(callee, llvm::Visibility::Hidden); |
