Add custom binding to SmallVector<Type*>

This commit is contained in:
Siu Kwan Lam 2013-01-22 21:23:20 -06:00
commit 6b88ffbaed
5 changed files with 51 additions and 8 deletions

View file

@ -2,14 +2,17 @@ from binding import *
from namespace import llvm
from LLVMContext import LLVMContext
from Type import Type
from SmallVector import SmallVector_Type
FunctionType = Type.Subclass()
FunctionType.include.add('llvm/DerivedTypes.h')
get = FunctionType.staticmultimethod([FunctionType.Pointer,
Type.Pointer, Bool.From(bool)],)
# (FunctionType.Pointer,
# Type.Pointer, )])
_get_signatures = [(FunctionType.Pointer,
Type.Pointer, Bool.From(bool)),
(FunctionType.Pointer,
Type.Pointer, SmallVector_Type.Ref, Bool.From(bool))]
get = FunctionType.staticmultimethod(*_get_signatures)
isVarArg = FunctionType.method(Bool.To(bool))
getReturnType = FunctionType.method(Type.Pointer)