about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/builder.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-09-18 17:51:26 +0000
committerbors <bors@rust-lang.org>2024-09-18 17:51:26 +0000
commitf79a912d9edc3ad4db910c0e93672ed5c65133fa (patch)
treebf50bb9019c80e56bbfc5451c54caa68035b17e6 /compiler/rustc_codegen_llvm/src/builder.rs
parent7fc70f870a1d11c3b104274d3a18112996cdec9a (diff)
parentc0951bbce262aab3c0dfdd9f3ebbc0bdf7543173 (diff)
downloadrust-f79a912d9edc3ad4db910c0e93672ed5c65133fa.tar.gz
rust-f79a912d9edc3ad4db910c0e93672ed5c65133fa.zip
Auto merge of #130519 - matthiaskrgr:rollup-l1hok4x, r=matthiaskrgr
Rollup of 5 pull requests

Successful merges:

 - #130457 (Cleanup codegen traits)
 - #130471 (Add zlib to musl dist image so rust-lld will support zlib compression for debug info there.)
 - #130507 (Improve handling of raw-idents in check-cfg)
 - #130509 (llvm-wrapper: adapt for LLVM API changes, second try)
 - #130510 (doc: the source of `LetStmt` can also be `AssignDesugar`)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/builder.rs')
-rw-r--r--compiler/rustc_codegen_llvm/src/builder.rs10
1 files changed, 2 insertions, 8 deletions
diff --git a/compiler/rustc_codegen_llvm/src/builder.rs b/compiler/rustc_codegen_llvm/src/builder.rs
index 40783825cae..577d0869866 100644
--- a/compiler/rustc_codegen_llvm/src/builder.rs
+++ b/compiler/rustc_codegen_llvm/src/builder.rs
@@ -93,8 +93,6 @@ impl HasTargetSpec for Builder<'_, '_, '_> {
 }
 
 impl<'tcx> LayoutOfHelpers<'tcx> for Builder<'_, '_, 'tcx> {
-    type LayoutOfResult = TyAndLayout<'tcx>;
-
     #[inline]
     fn handle_layout_err(&self, err: LayoutError<'tcx>, span: Span, ty: Ty<'tcx>) -> ! {
         self.cx.handle_layout_err(err, span, ty)
@@ -102,8 +100,6 @@ impl<'tcx> LayoutOfHelpers<'tcx> for Builder<'_, '_, 'tcx> {
 }
 
 impl<'tcx> FnAbiOfHelpers<'tcx> for Builder<'_, '_, 'tcx> {
-    type FnAbiOfResult = &'tcx FnAbi<'tcx, Ty<'tcx>>;
-
     #[inline]
     fn handle_fn_abi_err(
         &self,
@@ -124,10 +120,6 @@ impl<'ll, 'tcx> Deref for Builder<'_, 'll, 'tcx> {
     }
 }
 
-impl<'ll, 'tcx> HasCodegen<'tcx> for Builder<'_, 'll, 'tcx> {
-    type CodegenCx = CodegenCx<'ll, 'tcx>;
-}
-
 macro_rules! builder_methods_for_value_instructions {
     ($($name:ident($($arg:ident),*) => $llvm_capi:ident),+ $(,)?) => {
         $(fn $name(&mut self, $($arg: &'ll Value),*) -> &'ll Value {
@@ -139,6 +131,8 @@ macro_rules! builder_methods_for_value_instructions {
 }
 
 impl<'a, 'll, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
+    type CodegenCx = CodegenCx<'ll, 'tcx>;
+
     fn build(cx: &'a CodegenCx<'ll, 'tcx>, llbb: &'ll BasicBlock) -> Self {
         let bx = Builder::with_cx(cx);
         unsafe {