Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2483cbb commit a76fb5bCopy full SHA for a76fb5b
1 file changed
Grammar/Grammar
@@ -1,4 +1,8 @@
1
-# Grammar for Python, version 5
+# Grammar for Python, version 6
2
+
3
+# Changes since version 5:
4
+# Comparison operators '<=' '>' '<>' are now 1 token
5
+# Also support '!=' and '==' as alternatives for '<>' and '='
6
7
# Changes compared to version 4:
8
# Blank lines and lines only containing a comment are now eaten
@@ -68,7 +72,7 @@ test: and_test ('or' and_test)*
68
72
and_test: not_test ('and' not_test)*
69
73
not_test: 'not' not_test | comparison
70
74
comparison: expr (comp_op expr)*
71
-comp_op: '<'|'>'|'='|'>' '='|'<' '='|'<' '>'|'in'|'not' 'in'|'is'|'is' 'not'
75
+comp_op: '<'|'>'|'='|'>='|'<='|'<>'|'!='|'=='|'in'|'not' 'in'|'is'|'is' 'not'
76
expr: term (('+'|'-') term)*
77
term: factor (('*'|'/'|'%') factor)*
78
factor: ('+'|'-') factor | atom trailer*
0 commit comments