@@ -30,7 +30,7 @@ use rustc::hir;
3030use interfaces:: BuilderMethods ;
3131use mir:: constant:: const_alloc_to_llvm;
3232use mir:: place:: PlaceRef ;
33- use rustc_codegen_utils:: common:: { OperandBundleDef , TypeKind } ;
33+ use rustc_codegen_utils:: common:: TypeKind ;
3434
3535use libc:: { c_uint, c_char} ;
3636use std:: iter;
@@ -68,42 +68,6 @@ pub use context::CodegenCx;
6868*
6969*/
7070
71- /// A structure representing an active landing pad for the duration of a basic
72- /// block.
73- ///
74- /// Each `Block` may contain an instance of this, indicating whether the block
75- /// is part of a landing pad or not. This is used to make decision about whether
76- /// to emit `invoke` instructions (e.g. in a landing pad we don't continue to
77- /// use `invoke`) and also about various function call metadata.
78- ///
79- /// For GNU exceptions (`landingpad` + `resume` instructions) this structure is
80- /// just a bunch of `None` instances (not too interesting), but for MSVC
81- /// exceptions (`cleanuppad` + `cleanupret` instructions) this contains data.
82- /// When inside of a landing pad, each function call in LLVM IR needs to be
83- /// annotated with which landing pad it's a part of. This is accomplished via
84- /// the `OperandBundleDef` value created for MSVC landing pads.
85- pub struct Funclet < ' ll , V > {
86- cleanuppad : V ,
87- operand : OperandBundleDef < ' ll , V > ,
88- }
89-
90- impl < ' ll , V : CodegenObject > Funclet < ' ll , V > {
91- pub fn new ( cleanuppad : V ) -> Self {
92- Funclet {
93- cleanuppad,
94- operand : OperandBundleDef :: new ( "funclet" , cleanuppad) ,
95- }
96- }
97-
98- pub fn cleanuppad ( & self ) -> V {
99- self . cleanuppad
100- }
101-
102- pub fn bundle ( & self ) -> & OperandBundleDef < ' ll , V > {
103- & self . operand
104- }
105- }
106-
10771impl Backend < ' ll > for CodegenCx < ' ll , ' tcx , & ' ll Value > {
10872 type Value = & ' ll Value ;
10973 type BasicBlock = & ' ll BasicBlock ;
0 commit comments