about summary refs log tree commit diff
path: root/src/bootstrap/llvm.pry
diff options
context:
space:
mode:
authorBaitinq <[email protected]>2025-07-12 20:51:19 +0200
committerBaitinq <[email protected]>2025-07-12 20:51:19 +0200
commitd157bcfbd23e3dcb95c397f351fad4ddcc25349c (patch)
tree73e7845387f5a5cdce51849f25bcefcd85d21e6f /src/bootstrap/llvm.pry
parentBoostrap: Clean (diff)
downloadpry-lang-d157bcfbd23e3dcb95c397f351fad4ddcc25349c.tar.gz
pry-lang-d157bcfbd23e3dcb95c397f351fad4ddcc25349c.tar.bz2
pry-lang-d157bcfbd23e3dcb95c397f351fad4ddcc25349c.zip
Boostrap: Support calling function ptr
Diffstat (limited to 'src/bootstrap/llvm.pry')
-rw-r--r--src/bootstrap/llvm.pry5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/bootstrap/llvm.pry b/src/bootstrap/llvm.pry
index c4f7612..2ddcd2c 100644
--- a/src/bootstrap/llvm.pry
+++ b/src/bootstrap/llvm.pry
@@ -258,6 +258,7 @@ let LLVMTargetRef = newtype *void;
 let LLVMIntPredicate = newtype i64;
 
 let LLVMValueRef = newtype *void;
+let LLVMValueKind = newtype i64;
 let LLVMTypeRef = newtype *void;
 let LLVMBasicBlockRef = newtype *void;
 
@@ -321,6 +322,10 @@ extern LLVMBuildNeg = (LLVMBuilderRef, LLVMValueRef, *i8) => LLVMValueRef;
 extern LLVMBuildSub = (LLVMBuilderRef, LLVMValueRef, LLVMValueRef, *i8) => LLVMValueRef;
 extern LLVMBuildAdd = (LLVMBuilderRef, LLVMValueRef, LLVMValueRef, *i8) => LLVMValueRef;
 extern LLVMBuildGEP2 = (LLVMBuilderRef, LLVMTypeRef, LLVMValueRef, *LLVMValueRef, i64, *i8) => LLVMValueRef;
+extern LLVMAddGlobal = (LLVMModuleRef, LLVMTypeRef, *i8) => LLVMValueRef;
+extern LLVMSetInitializer = (LLVMValueRef, LLVMValueRef) => void;
+extern LLVMGetValueKind = (LLVMValueRef) => LLVMValueKind;
+let LLVMFunctionValueKind = cast(LLVMValueKind, 5);
 
 let LLVMIntEQ = 32;
 let LLVMIntNE = 33;