This commit is contained in:
Siu Kwan Lam 2013-05-14 11:23:50 -05:00
commit db7323771f
2 changed files with 7 additions and 1 deletions

View file

@ -1,6 +1,7 @@
from binding import *
from .namespace import llvm
from .Value import GlobalValue, Constant, Function, Argument, Value
from .Module import Module
from .BasicBlock import BasicBlock
from .ValueSymbolTable import ValueSymbolTable
from .Attributes import Attributes
@ -53,7 +54,11 @@ class Function:
removeFnAttr = Method(Void, ref(Attributes))
#hasFnAttribute = Method(cast(Bool, bool), Attributes.AttrVal)
Create = Method(ptr(Function))
Create = StaticMethod(ptr(Function),
ptr(FunctionType),
GlobalValue.LinkageTypes,
cast(str, ConstCharPtr),
ptr(Module)).require_only(2)
eraseFromParent = Method()
eraseFromParent.disowning = True

View file

@ -4,6 +4,7 @@ from .ADT.StringRef import StringRef
@ValueSymbolTable
class ValueSymbolTable:
_include_ = 'llvm/ValueSymbolTable.h'
new = Constructor()
delete = Destructor()
lookup = Method(ptr(Value), cast(str, StringRef))