Method AddFunction
AddFunction(String, IFunctionType)
Add a function with the specified signature to the module
Declaration
public IrFunction AddFunction(string name, IFunctionType signature)
Parameters
public IrFunction AddFunction(string name, IFunctionType signature)
String | name | Name of the function to add |
IFunctionType | signature | Signature of the function |
Returns
IrFunction | IrFunctionmatching the specified signature and name |
Remarks
If a matching function already exists it is returned, and therefore the returned IrFunction may have a body and additional attributes. If a function of the same name exists with a different signature an exception is thrown as LLVM does not perform any function overloading.