Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Q unit20120826 #75

Merged
merged 108 commits into from Sep 4, 2012
Merged

Q unit20120826 #75

merged 108 commits into from Sep 4, 2012

Commits on Feb 18, 2012

  1. modify the append_module method of the compiler to output a basic mod…

    …ule definition
    thenewguy authored and unknown committed Feb 18, 2012
    Configuration menu
    Copy the full SHA
    e6287f4 View commit details
    Browse the repository at this point in the history
  2. create a global namespace for modules in $PY.modules = {};

    thenewguy authored and unknown committed Feb 18, 2012
    Configuration menu
    Copy the full SHA
    b0718c6 View commit details
    Browse the repository at this point in the history

Commits on Feb 19, 2012

  1. Configuration menu
    Copy the full SHA
    8b30579 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7620e3e View commit details
    Browse the repository at this point in the history
  3. create the basic method that will be used to build references for var…

    …iable definitions. use it for class def
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    22f5354 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    8df8e4b View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    2c9a195 View commit details
    Browse the repository at this point in the history
  6. do not redefine self._funcs

    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    811289b View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    7801c6e View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    c223f3b View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    370eff3 View commit details
    Browse the repository at this point in the history
  10. add a command line flag to clean the tests before running them. does …

    …the equivalent of make testclean without requiring make
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    8a26789 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    4e41f1e View commit details
    Browse the repository at this point in the history
  12. add the option to compile code as a module. can also provide the base…

    … path to use for generating the dotted path.
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    7b3a649 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    9d92b89 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    544ced0 View commit details
    Browse the repository at this point in the history
  15. it is more useful to provide scope iterables than to provide methods …

    …for checking if a name is in scope
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    e8f753c View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    bc6e8e9 View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    12a02cb View commit details
    Browse the repository at this point in the history
  18. modify python compiler to use scoping properties defined in previous …

    …commit so that the attached test passes without causing any other tests to fail (verified on Windows)
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    c8a9d0f View commit details
    Browse the repository at this point in the history
  19. Configuration menu
    Copy the full SHA
    bfa1cf0 View commit details
    Browse the repository at this point in the history
  20. create a function that will act as the module initiation point. Named…

    … after runpy.run_module from http://docs.python.org/library/runpy.html#runpy.run_module
    
    Currently only sets __name__ and __builtins__.
    
    __name__ is set to "__main__" so that the standard if __name__ == "__main__" type code block can be used.
    
    __builtins__ is set to the pyjaco __builtins__ object.  Modules namespace __builtins__ so that it doesn't matter what the global builtin variable is named.
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    0ee1f28 View commit details
    Browse the repository at this point in the history
  21. move as_module tests and change how they are initialized. use the "st…

    …andard" if __name__ == "__main__" approach.
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    45f2602 View commit details
    Browse the repository at this point in the history
  22. check for "special globals" in visit_Name. Had to create a new util p…

    …ackage and move the special_global dict there so that they could be imported into the main pyjaco compiler and the python compiler without errors.
    thenewguy committed Feb 19, 2012
    Configuration menu
    Copy the full SHA
    b29f370 View commit details
    Browse the repository at this point in the history

Commits on Feb 20, 2012

  1. separate the calls for checking scope in visit_Name. This is more ver…

    …bose, but it is easy to see the order of preference for determining the final name.
    thenewguy committed Feb 20, 2012
    Configuration menu
    Copy the full SHA
    a5cbeb1 View commit details
    Browse the repository at this point in the history
  2. __file__, __loader__, and __package__ are not used at this time, so d…

    …o not define them yet.
    thenewguy committed Feb 20, 2012
    Configuration menu
    Copy the full SHA
    e8dca12 View commit details
    Browse the repository at this point in the history
  3. return the module definition from calls to run_module because python'…

    …s runpy.run_module returns "the resulting module globals dictionary"
    thenewguy committed Feb 20, 2012
    Configuration menu
    Copy the full SHA
    ac12f0c View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7e70419 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    d52f7b6 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    51665ac View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    93800f1 View commit details
    Browse the repository at this point in the history

Commits on Feb 21, 2012

  1. Configuration menu
    Copy the full SHA
    31509ae View commit details
    Browse the repository at this point in the history
  2. strip ".__init__" from the end of the dotted path because __init__.py…

    … files provide the module named by the directory name
    thenewguy committed Feb 21, 2012
    Configuration menu
    Copy the full SHA
    6b51f55 View commit details
    Browse the repository at this point in the history

Commits on Feb 22, 2012

  1. Configuration menu
    Copy the full SHA
    fdff148 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    a22cd1a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    2c6dfa4 View commit details
    Browse the repository at this point in the history
  4. had trouble getting .gitignore to work with an arbitrary number of su…

    …bdirectories. ** supposedly works with some OS. Windows doesn't appear to be one of them.
    thenewguy committed Feb 22, 2012
    Configuration menu
    Copy the full SHA
    493c767 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    830e9f7 View commit details
    Browse the repository at this point in the history
  6. cache imports

    thenewguy committed Feb 22, 2012
    Configuration menu
    Copy the full SHA
    abd5db1 View commit details
    Browse the repository at this point in the history
  7. Assume module exists in __import_cache, react if it doesn't. I think …

    …this is more readable.
    thenewguy committed Feb 22, 2012
    Configuration menu
    Copy the full SHA
    d9fadbc View commit details
    Browse the repository at this point in the history
  8. test "import foo as bar"

    thenewguy committed Feb 22, 2012
    Configuration menu
    Copy the full SHA
    9126f44 View commit details
    Browse the repository at this point in the history
  9. test single import statement with multiple imports separated by comma…

    … (i.e. import a, b, c)
    thenewguy committed Feb 22, 2012
    Configuration menu
    Copy the full SHA
    b4f0abe View commit details
    Browse the repository at this point in the history

Commits on Feb 27, 2012

  1. Configuration menu
    Copy the full SHA
    27e8190 View commit details
    Browse the repository at this point in the history
  2. namespace module variable definition inside the module definition to …

    …avoid name collisions with python code. in the future: should probably condense this down into one variable instead of using object hierarchy.
    thenewguy committed Feb 27, 2012
    Configuration menu
    Copy the full SHA
    2cbfa1b View commit details
    Browse the repository at this point in the history

Commits on Jul 4, 2012

  1. Configuration menu
    Copy the full SHA
    d8f5963 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5419fa6 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e933c6d View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    562f6ee View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    cd7d240 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    f404943 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    aff32cd View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    9431bb0 View commit details
    Browse the repository at this point in the history
  9. import_multi test passes

    thenewguy committed Jul 4, 2012
    Configuration menu
    Copy the full SHA
    ac50694 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    6fb40f9 View commit details
    Browse the repository at this point in the history

Commits on Jul 5, 2012

  1. Configuration menu
    Copy the full SHA
    1e33524 View commit details
    Browse the repository at this point in the history

Commits on Jul 6, 2012

  1. Configuration menu
    Copy the full SHA
    f84142b View commit details
    Browse the repository at this point in the history
  2. from_import passes

    thenewguy committed Jul 6, 2012
    Configuration menu
    Copy the full SHA
    095771a View commit details
    Browse the repository at this point in the history
  3. move test location

    thenewguy committed Jul 6, 2012
    Configuration menu
    Copy the full SHA
    7856257 View commit details
    Browse the repository at this point in the history

Commits on Jul 7, 2012

  1. Configuration menu
    Copy the full SHA
    a14253c View commit details
    Browse the repository at this point in the history
  2. work on lambda tests

    thenewguy committed Jul 7, 2012
    Configuration menu
    Copy the full SHA
    afa56ed View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    5a0491f View commit details
    Browse the repository at this point in the history

Commits on Jul 8, 2012

  1. Configuration menu
    Copy the full SHA
    7b8b9fe View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    958b7ad View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    58ade5f View commit details
    Browse the repository at this point in the history
  4. glob is grabbing previously compiled files that should not be tested …

    …like "tests/test_compile_js_as_module.py.js"
    thenewguy committed Jul 8, 2012
    Configuration menu
    Copy the full SHA
    2e83a0b View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    934de97 View commit details
    Browse the repository at this point in the history
  6. the line >>> name = self.build_ref("__getattr__('%s')" % name) <<< sh…

    …ould not have been committed.
    thenewguy committed Jul 8, 2012
    Configuration menu
    Copy the full SHA
    1529551 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    543e325 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    a86b330 View commit details
    Browse the repository at this point in the history
  9. add a kwarg on the compiler indent method that allows a fixed level o…

    …f indention. Useful for indenting a specific level for blocks.
    thenewguy committed Jul 8, 2012
    Configuration menu
    Copy the full SHA
    5441746 View commit details
    Browse the repository at this point in the history
  10. make try blocks easier to read by adjusting indentation and whitespac…

    …e for debugging purposes
    thenewguy committed Jul 8, 2012
    Configuration menu
    Copy the full SHA
    c4fa3b5 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    2fba308 View commit details
    Browse the repository at this point in the history

Commits on Jul 9, 2012

  1. Configuration menu
    Copy the full SHA
    666661c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    91e7ab8 View commit details
    Browse the repository at this point in the history

Commits on Jul 10, 2012

  1. Configuration menu
    Copy the full SHA
    3fa5d14 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    822e53a View commit details
    Browse the repository at this point in the history
  3. Throw a SyntaxWarning instead of SyntaxError when encountering a keyw…

    …ord in the package path.
    thenewguy committed Jul 10, 2012
    Configuration menu
    Copy the full SHA
    4b2dc0d View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    8bfcc74 View commit details
    Browse the repository at this point in the history
  5. add simple "try" test cases

    thenewguy committed Jul 10, 2012
    Configuration menu
    Copy the full SHA
    525649a View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    cadc2fa View commit details
    Browse the repository at this point in the history

Commits on Jul 11, 2012

  1. Configuration menu
    Copy the full SHA
    c966cc0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e9d2457 View commit details
    Browse the repository at this point in the history

Commits on Jul 14, 2012

  1. Configuration menu
    Copy the full SHA
    b164451 View commit details
    Browse the repository at this point in the history
  2. fix test "tests/functions/and.py" and others that were failing becaus…

    …e visit_AssignSimple added "var " to module references
    thenewguy committed Jul 14, 2012
    Configuration menu
    Copy the full SHA
    126b10a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    85faecd View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    54a3e62 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c8d2bc2 View commit details
    Browse the repository at this point in the history
  6. if the compiler is in module mode and has not yet encountered a local…

    … scope function definition for the function name being called in visit_Call, it is unclear where the call should reference. Push this decision into javascript with preference on local scope.
    thenewguy committed Jul 14, 2012
    Configuration menu
    Copy the full SHA
    eff659e View commit details
    Browse the repository at this point in the history

Commits on Jul 15, 2012

  1. Configuration menu
    Copy the full SHA
    9169aa9 View commit details
    Browse the repository at this point in the history
  2. Process exceptions in javascript catch blocks so that native javascri…

    …pt exceptions can be translated to their python equivalents. Specifically for this commit, translate JavaScript ReferenceError to Python NameError
    thenewguy committed Jul 15, 2012
    Configuration menu
    Copy the full SHA
    84ab87c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    96c587a View commit details
    Browse the repository at this point in the history

Commits on Jul 16, 2012

  1. Configuration menu
    Copy the full SHA
    afa1f31 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e14fc81 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e40d6c5 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    1d5030c View commit details
    Browse the repository at this point in the history

Commits on Jul 17, 2012

  1. adjust the fake console.log function such that it does not cause test…

    …s to fail based on how many arguments are sent to it
    thenewguy committed Jul 17, 2012
    Configuration menu
    Copy the full SHA
    0df3ad1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7a299ab View commit details
    Browse the repository at this point in the history
  3. manually keep track of QUnit test index because using enumerate can a…

    …llow test numbers to differ from the QUnit page if tests are skipped due to failing in python or etc
    thenewguy committed Jul 17, 2012
    Configuration menu
    Copy the full SHA
    19db7b7 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    77e3491 View commit details
    Browse the repository at this point in the history

Commits on Jul 18, 2012

  1. QUnit test fixes -- properly escape py_out and use a javascript array…

    … to hold test output in the browser until it is needed. Then join it with newlines.
    thenewguy committed Jul 18, 2012
    Configuration menu
    Copy the full SHA
    c3f5659 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    184f514 View commit details
    Browse the repository at this point in the history

Commits on Jul 19, 2012

  1. Configuration menu
    Copy the full SHA
    720fc82 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    be30110 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    067059d View commit details
    Browse the repository at this point in the history
  4. create a dummy "load" function instead of stripping the load call fro…

    …m tests because the way load was being stripped wasn't resilient to future changes to output
    thenewguy committed Jul 19, 2012
    Configuration menu
    Copy the full SHA
    4f5b92d View commit details
    Browse the repository at this point in the history
  5. test function needs to start with '"use strict";' in order to run the…

    … test in strict mode. QUnit tests were not previously being run in strict mode.
    thenewguy committed Jul 19, 2012
    Configuration menu
    Copy the full SHA
    7ecd545 View commit details
    Browse the repository at this point in the history

Commits on Jul 20, 2012

  1. compiled output needs to specify "use strict" and run without errors.…

    … Otherwise, concatenating the builtins with the compiled code causes errors.
    thenewguy committed Jul 20, 2012
    Configuration menu
    Copy the full SHA
    486dd27 View commit details
    Browse the repository at this point in the history

Commits on Jul 21, 2012

  1. Configuration menu
    Copy the full SHA
    a269bf3 View commit details
    Browse the repository at this point in the history