IRType
public protocol IRType
An IRType
is a type that is capable of lowering itself to an LLVMTypeRef
object for use with LLVM’s C API.
-
Retrieves the underlying LLVM type object.
Declaration
Swift
func asLLVM() -> LLVMTypeRef
-
null()
Extension methodReturns the special
null
value for this type.Declaration
Swift
func null() -> IRConstant
-
undef()
Extension methodReturns the special LLVM
undef
value for this type.The
undef
value can be used anywhere a constant is expected, and indicates that the user of the value may receive an unspecified bit-pattern.Declaration
Swift
func `undef`() -> IRValue
-
constPointerNull()
Extension methodReturns the special LLVM constant
null
pointer value for this type initialized tonull
.Declaration
Swift
func constPointerNull() -> IRConstant
-
context
Extension methodReturns the context associated with this type
Declaration
Swift
var context: Context { get }
-
scalarType
Extension methodIf this is a vector type, return the element type, otherwise return
self
.Declaration
Swift
var scalarType: IRType { get }