mod abi;
mod asm;
-mod backend;
mod builder;
mod consts;
mod debuginfo;
pub use self::abi::{AbiBuilderMethods, AbiMethods};
pub use self::asm::{AsmBuilderMethods, AsmMethods};
-pub use self::backend::{Backend, BackendTypes};
pub use self::builder::BuilderMethods;
pub use self::consts::ConstMethods;
pub use self::debuginfo::{DebugInfoBuilderMethods, DebugInfoMethods};
-pub use self::declare::DeclareMethods;
+pub use self::declare::{DeclareMethods, PreDefineMethods};
pub use self::intrinsic::{IntrinsicCallMethods, IntrinsicDeclarationMethods};
pub use self::misc::MiscMethods;
pub use self::statics::StaticMethods;
pub use self::type_::{
ArgTypeMethods, BaseTypeMethods, DerivedTypeMethods, LayoutTypeMethods, TypeMethods,
};
-
-use std::fmt;
+pub use rustc_codegen_ssa::interfaces::{Backend, BackendMethods, BackendTypes, CodegenObject};
pub trait CodegenMethods<'tcx>:
Backend<'tcx>
+ IntrinsicDeclarationMethods<'tcx>
+ DeclareMethods<'tcx>
+ AsmMethods<'tcx>
+ + PreDefineMethods<'tcx>
{
}
+ IntrinsicDeclarationMethods<'tcx>
+ DeclareMethods<'tcx>
+ AsmMethods<'tcx>
+ + PreDefineMethods<'tcx>
{}
pub trait HasCodegen<'tcx>: Backend<'tcx> {
BasicBlock = Self::BasicBlock,
Type = Self::Type,
Context = Self::Context,
+ Funclet = Self::Funclet,
DIScope = Self::DIScope,
>;
}
-
-pub trait CodegenObject: Copy + PartialEq + fmt::Debug {}
-impl<T: Copy + PartialEq + fmt::Debug> CodegenObject for T {}