Skip to content

Commit

Permalink
Temporary kludge for LLVM 3.7.1
Browse files Browse the repository at this point in the history
The signature for `LLVMBuildLandingPad` was accidentally changed in 3.7 and
reverted for 3.7.1. This removes the call since fcd doesn't use landing pads
anyway.

The LLVM 3.8 branch fixes the issue by having the build system generate the
bindings.cpp file.
  • Loading branch information
fay59 committed Feb 26, 2016
1 parent f69666a commit d884d45
Showing 1 changed file with 1 addition and 16 deletions.
17 changes: 1 addition & 16 deletions fcd/python/bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2080,22 +2080,7 @@ static PyObject* Py_LLVMBuilder_BuildLShr(Py_LLVM_Wrapped<LLVMBuilderRef>* self,

static PyObject* Py_LLVMBuilder_BuildLandingPad(Py_LLVM_Wrapped<LLVMBuilderRef>* self, PyObject* args)
{
Py_LLVM_Wrapped<LLVMTypeRef>* arg0;
long long arg1;
const char* arg2;
if (!PyArg_ParseTuple(args, "O!Ls", &Py_LLVMType_Type, &arg0, &arg1, &arg2))
{
return nullptr;
}

auto callReturn = LLVMBuildLandingPad(self->obj, arg0->obj, arg1, arg2);
if (callReturn == nullptr)
{
Py_RETURN_NONE;
}
Py_LLVM_Wrapped<LLVMValueRef>* result = PyObject_New(Py_LLVM_Wrapped<LLVMValueRef>, &Py_LLVMValue_Type);
result->obj = callReturn;
return (PyObject*)result;
Py_RETURN_NONE;
}

static PyObject* Py_LLVMBuilder_BuildLoad(Py_LLVM_Wrapped<LLVMBuilderRef>* self, PyObject* args)
Expand Down

0 comments on commit d884d45

Please sign in to comment.