Skip to content

Commit 410a2de

Browse files
committed
Rename {ArgAbi,IntrinsicCall}Methods.
They both are part of `BuilderMethods`, and so should have `Builder` in their name like all the other traits in `BuilderMethods`.
1 parent 6a35b5c commit 410a2de

File tree

7 files changed

+14
-14
lines changed

7 files changed

+14
-14
lines changed

compiler/rustc_codegen_gcc/src/intrinsic/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use rustc_codegen_ssa::errors::InvalidMonomorphization;
1313
use rustc_codegen_ssa::mir::operand::{OperandRef, OperandValue};
1414
use rustc_codegen_ssa::mir::place::{PlaceRef, PlaceValue};
1515
use rustc_codegen_ssa::traits::{
16-
ArgAbiMethods, BuilderMethods, ConstMethods, IntrinsicCallMethods,
16+
ArgAbiBuilderMethods, BuilderMethods, ConstMethods, IntrinsicCallBuilderMethods,
1717
};
1818
#[cfg(feature = "master")]
1919
use rustc_codegen_ssa::traits::{BaseTypeMethods, MiscMethods};
@@ -94,7 +94,7 @@ fn get_simple_intrinsic<'gcc, 'tcx>(
9494
Some(cx.context.get_builtin_function(gcc_name))
9595
}
9696

97-
impl<'a, 'gcc, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
97+
impl<'a, 'gcc, 'tcx> IntrinsicCallBuilderMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
9898
fn codegen_intrinsic_call(
9999
&mut self,
100100
instance: Instance<'tcx>,
@@ -448,7 +448,7 @@ impl<'a, 'gcc, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
448448
}
449449
}
450450

451-
impl<'a, 'gcc, 'tcx> ArgAbiMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
451+
impl<'a, 'gcc, 'tcx> ArgAbiBuilderMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
452452
fn store_fn_arg(
453453
&mut self,
454454
arg_abi: &ArgAbi<'tcx, Ty<'tcx>>,

compiler/rustc_codegen_llvm/src/abi.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ impl<'ll, 'tcx> ArgAbiExt<'ll, 'tcx> for ArgAbi<'tcx, Ty<'tcx>> {
285285
}
286286
}
287287

288-
impl<'ll, 'tcx> ArgAbiMethods<'tcx> for Builder<'_, 'll, 'tcx> {
288+
impl<'ll, 'tcx> ArgAbiBuilderMethods<'tcx> for Builder<'_, 'll, 'tcx> {
289289
fn store_fn_arg(
290290
&mut self,
291291
arg_abi: &ArgAbi<'tcx, Ty<'tcx>>,

compiler/rustc_codegen_llvm/src/intrinsic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ fn get_simple_intrinsic<'ll>(
148148
Some(cx.get_intrinsic(llvm_name))
149149
}
150150

151-
impl<'ll, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'_, 'll, 'tcx> {
151+
impl<'ll, 'tcx> IntrinsicCallBuilderMethods<'tcx> for Builder<'_, 'll, 'tcx> {
152152
fn codegen_intrinsic_call(
153153
&mut self,
154154
instance: ty::Instance<'tcx>,

compiler/rustc_codegen_ssa/src/traits/builder.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ use super::asm::AsmBuilderMethods;
1515
use super::consts::ConstMethods;
1616
use super::coverageinfo::CoverageInfoBuilderMethods;
1717
use super::debuginfo::DebugInfoBuilderMethods;
18-
use super::intrinsic::IntrinsicCallMethods;
18+
use super::intrinsic::IntrinsicCallBuilderMethods;
1919
use super::misc::MiscMethods;
20-
use super::type_::{ArgAbiMethods, BaseTypeMethods, LayoutTypeMethods};
20+
use super::type_::{ArgAbiBuilderMethods, BaseTypeMethods, LayoutTypeMethods};
2121
use super::{BackendTypes, CodegenMethods, StaticBuilderMethods};
2222
use crate::common::{
2323
AtomicOrdering, AtomicRmwBinOp, IntPredicate, RealPredicate, SynchronizationScope, TypeKind,
@@ -40,9 +40,9 @@ pub trait BuilderMethods<'a, 'tcx>:
4040
+ Deref<Target = Self::CodegenCx>
4141
+ CoverageInfoBuilderMethods<'tcx>
4242
+ DebugInfoBuilderMethods
43-
+ ArgAbiMethods<'tcx>
43+
+ ArgAbiBuilderMethods<'tcx>
4444
+ AbiBuilderMethods<'tcx>
45-
+ IntrinsicCallMethods<'tcx>
45+
+ IntrinsicCallBuilderMethods<'tcx>
4646
+ AsmBuilderMethods<'tcx>
4747
+ StaticBuilderMethods
4848
+ HasParamEnv<'tcx>

compiler/rustc_codegen_ssa/src/traits/intrinsic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use rustc_target::abi::call::FnAbi;
55
use super::BackendTypes;
66
use crate::mir::operand::OperandRef;
77

8-
pub trait IntrinsicCallMethods<'tcx>: BackendTypes {
8+
pub trait IntrinsicCallBuilderMethods<'tcx>: BackendTypes {
99
/// Remember to add all intrinsics here, in `compiler/rustc_hir_analysis/src/check/mod.rs`,
1010
/// and in `library/core/src/intrinsics.rs`; if you need access to any LLVM intrinsics,
1111
/// add them to `compiler/rustc_codegen_llvm/src/context.rs`.

compiler/rustc_codegen_ssa/src/traits/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,12 @@ pub use self::consts::ConstMethods;
3838
pub use self::coverageinfo::CoverageInfoBuilderMethods;
3939
pub use self::debuginfo::{DebugInfoBuilderMethods, DebugInfoMethods};
4040
pub use self::declare::PreDefineMethods;
41-
pub use self::intrinsic::IntrinsicCallMethods;
41+
pub use self::intrinsic::IntrinsicCallBuilderMethods;
4242
pub use self::misc::MiscMethods;
4343
pub use self::statics::{StaticBuilderMethods, StaticMethods};
4444
pub use self::type_::{
45-
ArgAbiMethods, BaseTypeMethods, DerivedTypeMethods, LayoutTypeMethods, TypeMembershipMethods,
46-
TypeMethods,
45+
ArgAbiBuilderMethods, BaseTypeMethods, DerivedTypeMethods, LayoutTypeMethods,
46+
TypeMembershipMethods, TypeMethods,
4747
};
4848
pub use self::write::{ModuleBufferMethods, ThinBufferMethods, WriteBackendMethods};
4949

compiler/rustc_codegen_ssa/src/traits/type_.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ pub trait TypeMembershipMethods<'tcx>: BackendTypes {
158158
fn set_kcfi_type_metadata(&self, _function: Self::Function, _typeid: u32) {}
159159
}
160160

161-
pub trait ArgAbiMethods<'tcx>: BackendTypes {
161+
pub trait ArgAbiBuilderMethods<'tcx>: BackendTypes {
162162
fn store_fn_arg(
163163
&mut self,
164164
arg_abi: &ArgAbi<'tcx, Ty<'tcx>>,

0 commit comments

Comments
 (0)