tjhance/pyston — pull request #1 by tjhance (2014-08-21 10:23:40+00:00)
Title: Future

- Added some syntax errors if you import __future__ incorrectly. To do this, traverses the AST to look for `from __future__ import` statements. Collects a list of __future__ flags enabled.
- Added the division future, and the ability to do truediv with ints and floats

To add truediv, I added a TrueDiv pseudo-AST-node and use that optype when generating the code. I guess it might make more sense to generate the AST using TrueDiv instead of Div (right now, I convert Div to TrueDiv at code generation time) but we don't have our own parser.

The __future__ module has an old-style class, so to get the tests to pass, I added an `allow-warning` directive for test cases. (Right now pyston spits out a warning for old-style classes, since it treats them as new-style.)