FunctionType
public struct FunctionType: IRType
FunctionType represents a function’s type signature. It consists of a
return type and a list of formal parameter types. The return type of a
function type is a void type or first class type — except for LabelType
and MetadataType.
-
The list of argument types.
Declaration
Swift
public let argTypes: [IRType] -
The return type of this function type.
Declaration
Swift
public let returnType: IRType -
Returns whether this function is variadic.
Declaration
Swift
public let isVarArg: Bool -
Creates a function type with the given argument types and return type.
Parameters
argTypesA list of the argument types of the function type.
returnTypeThe return type of the function type.
isVarArgIndicates whether this function type is variadic. Defaults to
false. -
Retrieves the underlying LLVM type object.
Declaration
Swift
public func asLLVM() -> LLVMTypeRef
FunctionType Struct Reference