rubysolo/dentaku — pull request #38 by schneidmaster (2014-12-23 00:07:19+00:00)
Title: Fix evaluation of negative exponents.

I found another issue related to unary minus:

```
Dentaku.evaluate('0 * 10 ^ -2')
#=> ZeroDivisionError: divided by 0
```

The problem is that the `:pow` operation only matches `:numeric, :pow, :numeric` when it should also match negative exponents, i.e. `:numeric, :pow, :subtract, :numeric`. As a result, the multiplication is evaluated first, then `0 ^ -2` is evaluated- this is `1 / (0 ** 2)` and produces the divide by zero error.

I solved it by adding a `:math_neg_pow` to match `:numeric, :pow, :subtract, :numeric` and evaluate negative exponents. Feel free to implement a different solution if you have a cleaner way to handle it :smile: