From: <fwi...@us...> - 2008-08-03 16:30:11
|
Revision: 5068 http://jython.svn.sourceforge.net/jython/?rev=5068&view=rev Author: fwierzbicki Date: 2008-08-03 16:30:08 +0000 (Sun, 03 Aug 2008) Log Message: ----------- Small change for Jython -- it will be too hard in the short term to use CPython's "Store" where Jython uses "AugStore" for AugAssigns. Eventually I do intend to fix this, but it will take a little more work in the compiler than I want to do just now. Modified Paths: -------------- branches/asm/Lib/test/test_ast.py Modified: branches/asm/Lib/test/test_ast.py =================================================================== --- branches/asm/Lib/test/test_ast.py 2008-08-03 14:42:44 UTC (rev 5067) +++ branches/asm/Lib/test/test_ast.py 2008-08-03 16:30:08 UTC (rev 5068) @@ -171,6 +171,7 @@ assert to_tuple(ast_tree) == o test_order(ast_tree, (0, 0)) +# XXX: AugStore added for Jython. Short term it is too hard to emit just "Store" as CPython does. #### EVERYTHING BELOW IS GENERATED ##### exec_results = [ ('Module', [('FunctionDef', (1, 0), 'f', ('arguments', [], None, None, []), [('Pass', (1, 9))], [])]), @@ -178,7 +179,7 @@ ('Module', [('FunctionDef', (1, 0), 'f', ('arguments', [], None, None, []), [('Return', (1, 8), ('Num', (1, 15), 1))], [])]), ('Module', [('Delete', (1, 0), [('Name', (1, 4), 'v', ('Del',))])]), ('Module', [('Assign', (1, 0), [('Name', (1, 0), 'v', ('Store',))], ('Num', (1, 4), 1))]), -('Module', [('AugAssign', (1, 0), ('Name', (1, 0), 'v', ('Store',)), ('Add',), ('Num', (1, 5), 1))]), +('Module', [('AugAssign', (1, 0), ('Name', (1, 0), 'v', ('AugStore',)), ('Add',), ('Num', (1, 5), 1))]), ('Module', [('Print', (1, 0), ('Name', (1, 8), 'f', ('Load',)), [('Num', (1, 11), 1)], False)]), ('Module', [('For', (1, 0), ('Name', (1, 4), 'v', ('Store',)), ('Name', (1, 9), 'v', ('Load',)), [('Pass', (1, 11))], [])]), ('Module', [('While', (1, 0), ('Name', (1, 6), 'v', ('Load',)), [('Pass', (1, 8))], [])]), This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |