Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,13 @@ def CIR_AnyFuncType : CIR_TypeBase<"::cir::FuncType", "function type">;

def CIR_AnyArrayType : CIR_TypeBase<"::cir::ArrayType", "array type">;

//===----------------------------------------------------------------------===//
// Exception Info Type predicates
//===----------------------------------------------------------------------===//

def CIR_AnyExceptionInfoType : CIR_TypeBase<
"::cir::ExceptionInfoType", "exception info type">;

//===----------------------------------------------------------------------===//
// Pointer Type predicates
//===----------------------------------------------------------------------===//
Expand Down Expand Up @@ -238,4 +245,9 @@ def CIR_PtrToFunc : CIR_PtrToType<CIR_AnyFuncType>;

def CIR_PtrToArray : CIR_PtrToType<CIR_AnyArrayType>;

def CIR_PtrToExceptionInfoType
: CIR_PtrToType<CIR_AnyExceptionInfoType>,
BuildableType<"$_builder.getType<" # cppType # ">("
"cir::ExceptionInfoType::get($_builder.getContext())))">;

#endif // CLANG_CIR_DIALECT_IR_CIRTYPECONSTRAINTS_TD
12 changes: 0 additions & 12 deletions clang/include/clang/CIR/Dialect/IR/CIRTypes.td
Original file line number Diff line number Diff line change
Expand Up @@ -505,18 +505,6 @@ def CIR_VoidType : CIR_Type<"Void", "void"> {

// Constraints

// Pointer to exception info
def ExceptionPtr : Type<
And<[
CPred<"::mlir::isa<::cir::PointerType>($_self)">,
CPred<"::mlir::isa<::cir::ExceptionInfoType>("
"::mlir::cast<::cir::PointerType>($_self).getPointee())">
]>, "!cir.eh_info*">,
BuildableType<
"cir::PointerType::get($_builder.getContext(),"
"cir::ExceptionInfoType::get($_builder.getContext()))"> {
}

// Vector of integral type
def IntegerVector : Type<
And<[
Expand Down
Loading