diff options
Diffstat (limited to '0001-Fix-problem-with-python-3.5.patch')
-rw-r--r-- | 0001-Fix-problem-with-python-3.5.patch | 44 |
1 files changed, 0 insertions, 44 deletions
diff --git a/0001-Fix-problem-with-python-3.5.patch b/0001-Fix-problem-with-python-3.5.patch deleted file mode 100644 index 2a475b6c35f8..000000000000 --- a/0001-Fix-problem-with-python-3.5.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 78154521097a852dd82c614580e730ab1cd132ad Mon Sep 17 00:00:00 2001 -From: Pascal Lamblin <lamblinp@iro.umontreal.ca> -Date: Tue, 22 Mar 2016 11:45:25 -0400 -Subject: [PATCH] Fix problem with python 3.5. - -It would raise a SystemError wrapping the IndexError already raised. ---- - theano/tensor/subtensor.py | 9 +++++++-- - 1 file changed, 7 insertions(+), 2 deletions(-) - -diff --git a/theano/tensor/subtensor.py b/theano/tensor/subtensor.py -index 4d3deca..112db06 100644 ---- a/theano/tensor/subtensor.py -+++ b/theano/tensor/subtensor.py -@@ -1956,6 +1956,7 @@ class AdvancedIncSubtensor1(Op): - copy_of_x = self.copy_of_x(x) - - return """ -+ PyObject* rval = NULL; - if (%(inplace)s) - { - if (%(x)s != %(out)s) -@@ -1971,12 +1972,16 @@ class AdvancedIncSubtensor1(Op): - %(out)s = %(copy_of_x)s; - } - PyObject *arglist = Py_BuildValue("OOOi",%(out)s, %(idx)s, %(y)s, %(inc_or_set)d); -- inplace_increment(NULL, arglist); -+ rval = inplace_increment(NULL, arglist); - Py_XDECREF(arglist); -+ if (rval == NULL) { -+ %(fail)s; -+ } -+ Py_XDECREF(rval); - """ % locals() - - def c_code_cache_version(self): -- return (1,) -+ return (2,) - - def perform(self, node, inp, out_): - # TODO opt to make this inplace --- -2.7.4 - |