[Numpy-svn] [numpy/numpy] 9fc5e6: BUG: Remove pointer cast from the PyArray_BYTES ma...

GitHub noreply@github....
Fri Nov 16 15:41:58 CST 2012


  Branch: refs/heads/maintenance/1.7.x
  Home:   https://github.com/numpy/numpy
  Commit: 9fc5e63be058cf4f3fdaecaf20c80131f6aa495f
      https://github.com/numpy/numpy/commit/9fc5e63be058cf4f3fdaecaf20c80131f6aa495f
  Author: Frederic <nouiz@nouiz.org>
  Date:   2012-11-13 (Tue, 13 Nov 2012)

  Changed paths:
    M numpy/core/include/numpy/ndarraytypes.h

  Log Message:
  -----------
  BUG: Remove pointer cast from the PyArray_BYTES macro.

This fixes a compilation problem encountered with numpy 1.7 when the
PyArray_BYTES macro was used as an lvalue in Theano. The macro worked as an
lvalue in 1.6 and in 1.7 only the struct name was changed, which makes the
problem a bit of a mystery, but Theano compiles with this fix.


  Commit: abf0489b69496af2c9e19f8bf41356fa511e5f1a
      https://github.com/numpy/numpy/commit/abf0489b69496af2c9e19f8bf41356fa511e5f1a
  Author: Charles Harris <charlesr.harris@gmail.com>
  Date:   2012-11-13 (Tue, 13 Nov 2012)

  Changed paths:
    M numpy/core/include/numpy/ndarraytypes.h

  Log Message:
  -----------
  BUG: Remove pointer cast from the PyArray_DATA macro.

This lets PyArray_DATA be used as an lvalue as some compilers raised an
error with the previous version. The type is now determined by the type of
the struct member and is char*.  PyArray_BYTES had the same problem when
used as an lvalue in Theano and the same fix is used here.  This problem
needs a bigger fix at some point as the function equivalent of the macro
does not return an lvalue.


  Commit: b56f31529f3e3992eca54a5e86f1db4f4306ccc2
      https://github.com/numpy/numpy/commit/b56f31529f3e3992eca54a5e86f1db4f4306ccc2
  Author: Ondřej Čertík <ondrej.certik@gmail.com>
  Date:   2012-11-16 (Fri, 16 Nov 2012)

  Changed paths:
    M numpy/core/include/numpy/ndarraytypes.h

  Log Message:
  -----------
  Merge pull request #2742 from certik/backport2709

Backport #2709


Compare: https://github.com/numpy/numpy/compare/3ecbac56ae13...b56f31529f3e


More information about the Numpy-svn mailing list