summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1996-01-12 00:51:44 (GMT)
committerGuido van Rossum <guido@python.org>1996-01-12 00:51:44 (GMT)
commit3d1f09557bd447b2e45bf90385391ffc16eafe13 (patch)
tree6b0e7a3dcef1fbd8f0611b79916429bb1c19c6c9 /Include
parentb17d5dea4872f73b2e48f8236a60a2c6e74e7067 (diff)
downloadcpython-3d1f09557bd447b2e45bf90385391ffc16eafe13.zip
cpython-3d1f09557bd447b2e45bf90385391ffc16eafe13.tar.gz
cpython-3d1f09557bd447b2e45bf90385391ffc16eafe13.tar.bz2
changes for ** (power) operator
Diffstat (limited to 'Include')
-rw-r--r--Include/graminit.h21
-rw-r--r--Include/opcode.h2
-rw-r--r--Include/token.h7
3 files changed, 17 insertions, 13 deletions
diff --git a/Include/graminit.h b/Include/graminit.h
index e541099..9fa64c2 100644
--- a/Include/graminit.h
+++ b/Include/graminit.h
@@ -43,13 +43,14 @@
#define arith_expr 298
#define term 299
#define factor 300
-#define atom 301
-#define lambdef 302
-#define trailer 303
-#define subscript 304
-#define exprlist 305
-#define testlist 306
-#define dictmaker 307
-#define classdef 308
-#define arglist 309
-#define argument 310
+#define power 301
+#define atom 302
+#define lambdef 303
+#define trailer 304
+#define subscript 305
+#define exprlist 306
+#define testlist 307
+#define dictmaker 308
+#define classdef 309
+#define arglist 310
+#define argument 311
diff --git a/Include/opcode.h b/Include/opcode.h
index 9725580..401f765 100644
--- a/Include/opcode.h
+++ b/Include/opcode.h
@@ -43,6 +43,8 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#define UNARY_INVERT 15
+#define BINARY_POWER 19
+
#define BINARY_MULTIPLY 20
#define BINARY_DIVIDE 21
#define BINARY_MODULO 22
diff --git a/Include/token.h b/Include/token.h
index 2be3a30..4558525 100644
--- a/Include/token.h
+++ b/Include/token.h
@@ -66,10 +66,11 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#define CIRCUMFLEX 33
#define LEFTSHIFT 34
#define RIGHTSHIFT 35
+#define DOUBLESTAR 36
/* Don't forget to update the table _PyParser_TokenNames in tokenizer.c! */
-#define OP 36
-#define ERRORTOKEN 37
-#define N_TOKENS 38
+#define OP 37
+#define ERRORTOKEN 38
+#define N_TOKENS 39
/* Special definitions for cooperation with parser */