[Numpy-svn] [numpy/numpy] da40eb: BUG: core: allow scalar type richcompare to call n...

GitHub noreply at github.com
Wed May 14 15:04:01 EDT 2014


  Branch: refs/heads/maintenance/1.9.x
  Home:   https://github.com/numpy/numpy
  Commit: da40eba435d2b39c7d251f91d446ed411d71d3f5
      https://github.com/numpy/numpy/commit/da40eba435d2b39c7d251f91d446ed411d71d3f5
  Author: Pauli Virtanen <pav at iki.fi>
  Date:   2014-05-14 (Wed, 14 May 2014)

  Changed paths:
    M numpy/core/src/multiarray/scalartypes.c.src
    M numpy/core/tests/test_regression.py

  Log Message:
  -----------
  BUG: core: allow scalar type richcompare to call ndarray-subclass methods

This makes the scalar richcmp behave exactly as
"array(self) <op> other". The difference comes in when "other" is an ndarray
subclass, in which case this change allows the subclass to override the
comparison operations via usual Python binop dispatch rules.


  Commit: 9590c04e996a2c5c958652bd4e403786e6f9cce2
      https://github.com/numpy/numpy/commit/9590c04e996a2c5c958652bd4e403786e6f9cce2
  Author: Julian Taylor <juliantaylor108 at gmail.com>
  Date:   2014-05-14 (Wed, 14 May 2014)

  Changed paths:
    M numpy/core/src/multiarray/scalartypes.c.src
    M numpy/core/tests/test_regression.py

  Log Message:
  -----------
  Merge pull request #4711 from pv/scalar-richcmp-fix

BUG: core: allow scalar type richcompare to call ndarray-subclass methods


Compare: https://github.com/numpy/numpy/compare/afe32d77b354...9590c04e996a


More information about the Numpy-svn mailing list