Skip to content

Commit

Permalink
Fix for #286
Browse files Browse the repository at this point in the history
  • Loading branch information
robbmcleod committed Sep 20, 2017
1 parent 6d5ebac commit 6af5555
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions RELEASE_NOTES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Release notes for Numexpr 2.6 series
=====================================

Changes from 2.6.4 to 2.6.5
---------------------------

- Fixed a bug whereby all-constant power operations would lead to infinite
recursion.

Changes from 2.6.3 to 2.6.4
---------------------------

Expand Down
2 changes: 1 addition & 1 deletion numexpr/expressions.py
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ def pow_op(a, b):
'Integers to negative integer powers are not allowed.')

if allConstantNodes([a, b]):
return ConstantNode(a ** b)
return ConstantNode(a.value ** b.value)
if isinstance(b, ConstantNode):
x = b.value
if get_optimization() == 'aggressive':
Expand Down

0 comments on commit 6af5555

Please sign in to comment.