| CODENOTIFIER | HelpYou are not signed inSign in |
Project: Jython
Revision: 5220
Author: fwierzbicki
Date: 20 Aug 2008 11:37:02
Changes:Diff:| ... | ...@@ -80,7 +80,6 @@ | |
| 80 | 80 | Expression; |
| 81 | 81 | Ellipsis; |
| 82 | 82 | ListComp; |
| 83 | Repr; | |
| 84 | 83 | Target; |
| 85 | 84 | GeneratorExp; |
| 86 | 85 | Ifs; |
| ... | ...@@ -88,7 +87,6 @@ | |
| 88 | 87 | |
| 89 | 88 | GenFor; |
| 90 | 89 | GenIf; |
| 91 | ListFor; | |
| 92 | 90 | ListIf; |
| 93 | 91 | |
| 94 | 92 | } |
| ... | ...@@ -139,10 +137,11 @@ | |
| 139 | 137 | import org.python.antlr.ast.Module; |
| 140 | 138 | import org.python.antlr.ast.Name; |
| 141 | 139 | import org.python.antlr.ast.Num; |
| 140 | import org.python.antlr.ast.operatorType; | |
| 142 | 141 | import org.python.antlr.ast.Pass; |
| 143 | 142 | import org.python.antlr.ast.Print; |
| 144 | 143 | import org.python.antlr.ast.Raise; |
| 145 | import org.python.antlr.ast.operatorType; | |
| 144 | import org.python.antlr.ast.Repr; | |
| 146 | 145 | import org.python.antlr.ast.Return; |
| 147 | 146 | import org.python.antlr.ast.Slice; |
| 148 | 147 | import org.python.antlr.ast.sliceType; |
| ... | ...@@ -775,7 +774,7 @@ | |
| 775 | 774 | //test: or_test ['if' or_test 'else' test] | lambdef |
| 776 | 775 | test[expr_contextType ctype] |
| 777 | 776 | :o1=or_test[ctype] |
| 778 | ( (IF or_test[expr_contextType.Load] ORELSE) => IF o2=or_test[expr_contextType.Load] ORELSE e=test[expr_contextType.Load] | |
| 777 | ( (IF or_test[expr_contextType.Load] ORELSE) => IF o2=or_test[ctype] ORELSE e=test[expr_contextType.Load] | |
| 779 | 778 | -> ^(IF<IfExp>[$IF, (exprType)$o2.tree, (exprType)$o1.tree, (exprType)$e.tree]) |
| 780 | 779 | | -> or_test |
| 781 | 780 | ) |
| ... | ...@@ -1000,7 +999,7 @@ | |
| 1000 | 999 | | -> ^(LCURLY<Dict>[$LCURLY, new exprType[0\], new exprType[0\]]) |
| 1001 | 1000 | ) |
| 1002 | 1001 | RCURLY |
| 1003 | | BACKQUOTE testlist[expr_contextType.Load] BACKQUOTE -> ^(Repr BACKQUOTE testlist) | |
| 1002 | | lb=BACKQUOTE testlist[expr_contextType.Load] rb=BACKQUOTE -> ^(BACKQUOTE<Repr>[$lb, (exprType)$testlist.tree]) | |
| 1004 | 1003 | | NAME -> ^(PYNODE<Name>[$NAME, $NAME.text, $expr::ctype]) |
| 1005 | 1004 | | INT -> ^(PYNODE<Num>[$INT, actions.makeInt($INT)]) |
| 1006 | 1005 | | LONGINT -> ^(PYNODE<Num>[$LONGINT, actions.makeInt($LONGINT)]) |