[Python-checkins] CVS: python/dist/src/Include compile.h,2.29,2.29.6.1 frameobject.h,2.31,2.31.6.1 graminit.h,2.16,2.16.10.1 opcode.h,2.35,2.35.4.1 symtable.h,2.7,2.7.6.1

Guido van Rossum gvanrossum@users.sourceforge.net
Fri, 15 Jun 2001 11:56:46 -0700


Update of /cvsroot/python/python/dist/src/Include
In directory usw-pr-cvs1:/tmp/cvs-serv5899/Include

Modified Files:
      Tag: gen-branch
	compile.h frameobject.h graminit.h opcode.h symtable.h 
Log Message:
Neil's generator patch, in the gen-branch.

Index: compile.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/compile.h,v
retrieving revision 2.29
retrieving revision 2.29.6.1
diff -C2 -r2.29 -r2.29.6.1
*** compile.h	2001/03/22 02:32:48	2.29
--- compile.h	2001/06/15 18:56:44	2.29.6.1
***************
*** 34,37 ****
--- 34,38 ----
  #define CO_VARKEYWORDS	0x0008
  #define CO_NESTED       0x0010
+ #define CO_GENERATOR    0x0020
  
  extern DL_IMPORT(PyTypeObject) PyCode_Type;

Index: frameobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/frameobject.h,v
retrieving revision 2.31
retrieving revision 2.31.6.1
diff -C2 -r2.31 -r2.31.6.1
*** frameobject.h	2001/03/13 01:58:21	2.31
--- frameobject.h	2001/06/15 18:56:44	2.31.6.1
***************
*** 22,25 ****
--- 22,27 ----
      PyObject *f_locals;		/* local symbol table (PyDictObject) */
      PyObject **f_valuestack;	/* points after the last local */
+     PyObject **f_stackbottom;   /* points to the last item on the stack if
+                                   frame has yielded. */
      PyObject *f_trace;		/* Trace function */
      PyObject *f_exc_type, *f_exc_value, *f_exc_traceback;

Index: graminit.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/graminit.h,v
retrieving revision 2.16
retrieving revision 2.16.10.1
diff -C2 -r2.16 -r2.16.10.1
*** graminit.h	2000/08/24 20:09:45	2.16
--- graminit.h	2001/06/15 18:56:44	2.16.10.1
***************
*** 19,64 ****
  #define continue_stmt 274
  #define return_stmt 275
! #define raise_stmt 276
! #define import_stmt 277
! #define import_as_name 278
! #define dotted_as_name 279
! #define dotted_name 280
! #define global_stmt 281
! #define exec_stmt 282
! #define assert_stmt 283
! #define compound_stmt 284
! #define if_stmt 285
! #define while_stmt 286
! #define for_stmt 287
! #define try_stmt 288
! #define except_clause 289
! #define suite 290
! #define test 291
! #define and_test 292
! #define not_test 293
! #define comparison 294
! #define comp_op 295
! #define expr 296
! #define xor_expr 297
! #define and_expr 298
! #define shift_expr 299
! #define arith_expr 300
! #define term 301
! #define factor 302
! #define power 303
! #define atom 304
! #define listmaker 305
! #define lambdef 306
! #define trailer 307
! #define subscriptlist 308
! #define subscript 309
! #define sliceop 310
! #define exprlist 311
! #define testlist 312
! #define dictmaker 313
! #define classdef 314
! #define arglist 315
! #define argument 316
! #define list_iter 317
! #define list_for 318
! #define list_if 319
--- 19,65 ----
  #define continue_stmt 274
  #define return_stmt 275
! #define yield_stmt 276
! #define raise_stmt 277
! #define import_stmt 278
! #define import_as_name 279
! #define dotted_as_name 280
! #define dotted_name 281
! #define global_stmt 282
! #define exec_stmt 283
! #define assert_stmt 284
! #define compound_stmt 285
! #define if_stmt 286
! #define while_stmt 287
! #define for_stmt 288
! #define try_stmt 289
! #define except_clause 290
! #define suite 291
! #define test 292
! #define and_test 293
! #define not_test 294
! #define comparison 295
! #define comp_op 296
! #define expr 297
! #define xor_expr 298
! #define and_expr 299
! #define shift_expr 300
! #define arith_expr 301
! #define term 302
! #define factor 303
! #define power 304
! #define atom 305
! #define listmaker 306
! #define lambdef 307
! #define trailer 308
! #define subscriptlist 309
! #define subscript 310
! #define sliceop 311
! #define exprlist 312
! #define testlist 313
! #define dictmaker 314
! #define classdef 315
! #define arglist 316
! #define argument 317
! #define list_iter 318
! #define list_for 319
! #define list_if 320

Index: opcode.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/opcode.h,v
retrieving revision 2.35
retrieving revision 2.35.4.1
diff -C2 -r2.35 -r2.35.4.1
*** opcode.h	2001/04/20 19:13:01	2.35
--- opcode.h	2001/06/15 18:56:44	2.35.4.1
***************
*** 72,75 ****
--- 72,76 ----
  #define IMPORT_STAR	84
  #define EXEC_STMT	85
+ #define YIELD_VALUE	86
  
  #define POP_BLOCK	87

Index: symtable.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/symtable.h,v
retrieving revision 2.7
retrieving revision 2.7.6.1
diff -C2 -r2.7 -r2.7.6.1
*** symtable.h	2001/03/22 03:57:58	2.7
--- symtable.h	2001/06/15 18:56:44	2.7.6.1
***************
*** 47,50 ****
--- 47,51 ----
  	int ste_child_free;      /* true if a child scope has free variables,
  				    including free refs to globals */
+ 	int ste_generator;       /* true if namespace is a generator */
  	int ste_opt_lineno;      /* lineno of last exec or import * */
  	struct symtable *ste_table;