Skip to content

Commit e83bbc9

Browse files
committed
Get the error message from the error
Not the JIT stack
1 parent b876a1b commit e83bbc9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/LLVM/JIT.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ public final class JIT {
265265

266266
switch LLVMGetErrorTypeId(err)! {
267267
case LLVMGetStringErrorTypeId():
268-
guard let msg = LLVMGetErrorMessage(self.llvm) else {
268+
guard let msg = LLVMGetErrorMessage(err) else {
269269
fatalError("Couldn't get the error message?")
270270
}
271271
throw JITError.generic(String(cString: msg))

0 commit comments

Comments
 (0)