Commits

rndblnch committed 6014d17

moved PyStopIterationObject inside Py_LIMITED_API define in pyerrors.h; bumped to current cpython tip <http://hg.python.org/cpython/rev/328fb2bbcd56>;

Comments (0)

Files changed (2)

 # HG changeset patch
-# Parent 203407036e4617e8f6f9d094caef4ae46441392a
+# Parent 328fb2bbcd56cd83cafbf034dd1a527a9347b7dc
 
-diff -r 203407036e46 Grammar/Grammar
---- a/Grammar/Grammar	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Grammar/Grammar	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Grammar/Grammar
+--- a/Grammar/Grammar	Mon Jun 27 09:19:02 2011 -0500
++++ b/Grammar/Grammar	Mon Jun 27 16:51:07 2011 +0200
 @@ -119,7 +119,7 @@
                           |'**' test)
  # The reason that keywords are test nodes instead of NAME is that using NAME
 +yield_expr: 'yield' [yield_arg]
 +yield_arg: 'from' test | testlist
 +yield_from: 'yield' 'from' test
-diff -r 203407036e46 Include/frameobject.h
---- a/Include/frameobject.h	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Include/frameobject.h	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Include/frameobject.h
+--- a/Include/frameobject.h	Mon Jun 27 09:19:02 2011 -0500
++++ b/Include/frameobject.h	Mon Jun 27 16:51:07 2011 +0200
 @@ -27,6 +27,7 @@
         to the current stack top. */
      PyObject **f_stacktop;
  
  	/* In a generator, we need to be able to swap between the exception
  	   state inside the generator and the exception state of the calling
-diff -r 203407036e46 Include/genobject.h
---- a/Include/genobject.h	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Include/genobject.h	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Include/genobject.h
+--- a/Include/genobject.h	Mon Jun 27 09:19:02 2011 -0500
++++ b/Include/genobject.h	Mon Jun 27 16:51:07 2011 +0200
 @@ -34,6 +34,7 @@
  
  PyAPI_FUNC(PyObject *) PyGen_New(struct _frame *);
  
  #ifdef __cplusplus
  }
-diff -r 203407036e46 Include/opcode.h
---- a/Include/opcode.h	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Include/opcode.h	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Include/opcode.h
+--- a/Include/opcode.h	Mon Jun 27 09:19:02 2011 -0500
++++ b/Include/opcode.h	Mon Jun 27 16:51:07 2011 +0200
 @@ -53,6 +53,7 @@
  #define STORE_LOCALS	69
  #define PRINT_EXPR	70
  
  #define INPLACE_LSHIFT	75
  #define INPLACE_RSHIFT	76
-diff -r 203407036e46 Include/pyerrors.h
---- a/Include/pyerrors.h	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Include/pyerrors.h	Fri Jun 17 22:00:43 2011 +0200
-@@ -58,6 +58,11 @@
- #endif
- #endif
+diff -r 328fb2bbcd56 Include/pyerrors.h
+--- a/Include/pyerrors.h	Mon Jun 27 09:19:02 2011 -0500
++++ b/Include/pyerrors.h	Mon Jun 27 16:51:07 2011 +0200
+@@ -47,6 +47,11 @@
+     PyObject *filename;
+ } PyEnvironmentErrorObject;
  
 +typedef struct {
 +    PyException_HEAD
 +    PyObject *value;
 +} PyStopIterationObject;
 +
- /* Error handling definitions */
- 
- PyAPI_FUNC(void) PyErr_SetNone(PyObject *);
+ #ifdef MS_WINDOWS
+ typedef struct {
+     PyException_HEAD
 @@ -356,6 +361,8 @@
      const char *reason          /* UTF-8 encoded string */
      );
  
  /* These APIs aren't really part of the error implementation, but
     often needed to format error messages; the native C lib APIs are
-diff -r 203407036e46 Lib/opcode.py
---- a/Lib/opcode.py	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Lib/opcode.py	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Lib/opcode.py
+--- a/Lib/opcode.py	Mon Jun 27 09:19:02 2011 -0500
++++ b/Lib/opcode.py	Mon Jun 27 16:51:07 2011 +0200
 @@ -88,6 +88,7 @@
  
  def_op('PRINT_EXPR', 70)
  
  def_op('INPLACE_LSHIFT', 75)
  def_op('INPLACE_RSHIFT', 76)
-diff -r 203407036e46 Lib/test/test_generators.py
---- a/Lib/test/test_generators.py	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Lib/test/test_generators.py	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Lib/test/test_generators.py
+--- a/Lib/test/test_generators.py	Mon Jun 27 09:19:02 2011 -0500
++++ b/Lib/test/test_generators.py	Mon Jun 27 16:51:07 2011 +0200
 @@ -728,29 +728,6 @@
  
  syntax_tests = """
  >>> def f(): x = yield = y
  Traceback (most recent call last):
    ...
-diff -r 203407036e46 Lib/test/test_grammar.py
---- a/Lib/test/test_grammar.py	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Lib/test/test_grammar.py	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Lib/test/test_grammar.py
+--- a/Lib/test/test_grammar.py	Mon Jun 27 09:19:02 2011 -0500
++++ b/Lib/test/test_grammar.py	Mon Jun 27 16:51:07 2011 +0200
 @@ -459,6 +459,7 @@
  
      def test_yield(self):
  
      def test_raise(self):
          # 'raise' test [',' test]
-diff -r 203407036e46 Lib/test/test_parser.py
---- a/Lib/test/test_parser.py	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Lib/test/test_parser.py	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Lib/test/test_parser.py
+--- a/Lib/test/test_parser.py	Mon Jun 27 09:19:02 2011 -0500
++++ b/Lib/test/test_parser.py	Mon Jun 27 16:51:07 2011 +0200
 @@ -50,6 +50,10 @@
          self.check_suite("def f(): (yield 1)*2")
          self.check_suite("def f(): return; yield 1")
          self.check_suite("def f():\n"
                           "    for x in range(30):\n"
                           "        yield x\n")
-diff -r 203407036e46 Lib/test/test_sys.py
---- a/Lib/test/test_sys.py	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Lib/test/test_sys.py	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Lib/test/test_sys.py
+--- a/Lib/test/test_sys.py	Mon Jun 27 09:19:02 2011 -0500
++++ b/Lib/test/test_sys.py	Mon Jun 27 16:51:07 2011 +0200
 @@ -726,7 +726,7 @@
          nfrees = len(x.f_code.co_freevars)
          extras = x.f_code.co_stacksize + x.f_code.co_nlocals +\
          # function
          def func(): pass
          check(func, size(h + '11P'))
-diff -r 203407036e46 Modules/parsermodule.c
---- a/Modules/parsermodule.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Modules/parsermodule.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Modules/parsermodule.c
+--- a/Modules/parsermodule.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Modules/parsermodule.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -976,6 +976,7 @@
  VALIDATER(testlist_comp);       VALIDATER(yield_expr);
  VALIDATER(or_test);
      if (res && (nch == 2))
          res = validate_comp_for(CHILD(tree, 1));
      else if (res && (nch == 3))
-diff -r 203407036e46 Objects/exceptions.c
---- a/Objects/exceptions.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Objects/exceptions.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Objects/exceptions.c
+--- a/Objects/exceptions.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Objects/exceptions.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -471,8 +471,65 @@
  /*
   *    StopIteration extends Exception
  
  
  /*
-diff -r 203407036e46 Objects/frameobject.c
---- a/Objects/frameobject.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Objects/frameobject.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Objects/frameobject.c
+--- a/Objects/frameobject.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Objects/frameobject.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -15,11 +15,12 @@
  #define OFF(x) offsetof(PyFrameObject, x)
  
  
      _PyObject_GC_TRACK(f);
      return f;
-diff -r 203407036e46 Objects/genobject.c
---- a/Objects/genobject.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Objects/genobject.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Objects/genobject.c
+--- a/Objects/genobject.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Objects/genobject.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -5,6 +5,9 @@
  #include "structmember.h"
  #include "opcode.h"
  
  static PyObject *
  gen_repr(PyGenObject *gen)
-diff -r 203407036e46 Parser/Python.asdl
---- a/Parser/Python.asdl	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Parser/Python.asdl	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Parser/Python.asdl
+--- a/Parser/Python.asdl	Mon Jun 27 09:19:02 2011 -0500
++++ b/Parser/Python.asdl	Mon Jun 27 16:51:07 2011 +0200
 @@ -59,7 +59,7 @@
  	     | DictComp(expr key, expr value, comprehension* generators)
  	     | GeneratorExp(expr elt, comprehension* generators)
  	     -- need sequences for compare to distinguish between
  	     -- x < 4 < 3 and (x < 4) < 3
  	     | Compare(expr left, cmpop* ops, expr* comparators)
-diff -r 203407036e46 Python/ast.c
---- a/Python/ast.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Python/ast.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Python/ast.c
+--- a/Python/ast.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Python/ast.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -1895,13 +1895,28 @@
              }
              return ast_for_binop(c, n);
        raise_stmt: 'raise' [test [',' test [',' test]]]
      */
      node *ch;
-diff -r 203407036e46 Python/ceval.c
---- a/Python/ceval.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Python/ceval.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Python/ceval.c
+--- a/Python/ceval.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Python/ceval.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -1861,8 +1861,47 @@
              why = WHY_RETURN;
              goto fast_block_end;
              f->f_stacktop = stack_pointer;
              why = WHY_YIELD;
              /* Put aside the current exception state and restore
-diff -r 203407036e46 Python/compile.c
---- a/Python/compile.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Python/compile.c	Fri Jun 17 22:00:43 2011 +0200
+diff -r 328fb2bbcd56 Python/compile.c
+--- a/Python/compile.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Python/compile.c	Mon Jun 27 16:51:07 2011 +0200
 @@ -763,6 +763,7 @@
          case IMPORT_STAR:
              return -1;
          break;
      case Compare_kind:
          return compiler_compare(c, e);
-diff -r 203407036e46 Python/symtable.c
---- a/Python/symtable.c	Fri Jun 17 21:10:21 2011 +0200
-+++ b/Python/symtable.c	Fri Jun 17 22:00:43 2011 +0200
-@@ -1162,14 +1162,6 @@
+diff -r 328fb2bbcd56 Python/symtable.c
+--- a/Python/symtable.c	Mon Jun 27 09:19:02 2011 -0500
++++ b/Python/symtable.c	Mon Jun 27 16:51:07 2011 +0200
+@@ -1166,14 +1166,6 @@
          if (s->v.Return.value) {
              VISIT(st, expr, s->v.Return.value);
              st->st_cur->ste_returns_value = 1;
          }
          break;
      case Delete_kind:
-@@ -1371,13 +1363,6 @@
+@@ -1375,13 +1367,6 @@
          if (e->v.Yield.value)
              VISIT(st, expr, e->v.Yield.value);
          st->st_cur->ste_generator = 1;
 # HG changeset patch
-# Parent 7765c3f79e47fb8305c4ef05edb8b654d348fedc
+# Parent 8720ab7944b4d4160bd23557edebf353bbfde4f5
 
-diff -r 7765c3f79e47 Include/Python-ast.h
---- a/Include/Python-ast.h	Fri Jun 17 22:00:44 2011 +0200
-+++ b/Include/Python-ast.h	Fri Jun 17 22:06:32 2011 +0200
+diff -r 8720ab7944b4 Include/Python-ast.h
+--- a/Include/Python-ast.h	Mon Jun 27 16:51:08 2011 +0200
++++ b/Include/Python-ast.h	Mon Jun 27 17:00:20 2011 +0200
 @@ -245,6 +245,7 @@
                  } GeneratorExp;
                  
  #define Compare(a0, a1, a2, a3, a4, a5) _Py_Compare(a0, a1, a2, a3, a4, a5)
  expr_ty _Py_Compare(expr_ty left, asdl_int_seq * ops, asdl_seq * comparators,
                      int lineno, int col_offset, PyArena *arena);
-diff -r 7765c3f79e47 Include/graminit.h
---- a/Include/graminit.h	Fri Jun 17 22:00:44 2011 +0200
-+++ b/Include/graminit.h	Fri Jun 17 22:06:32 2011 +0200
+diff -r 8720ab7944b4 Include/graminit.h
+--- a/Include/graminit.h	Mon Jun 27 16:51:08 2011 +0200
++++ b/Include/graminit.h	Mon Jun 27 17:00:20 2011 +0200
 @@ -81,3 +81,5 @@
  #define comp_if 334
  #define encoding_decl 335
  #define yield_expr 336
 +#define yield_arg 337
 +#define yield_from 338
-diff -r 7765c3f79e47 Python/Python-ast.c
---- a/Python/Python-ast.c	Fri Jun 17 22:00:44 2011 +0200
-+++ b/Python/Python-ast.c	Fri Jun 17 22:06:32 2011 +0200
+diff -r 8720ab7944b4 Python/Python-ast.c
+--- a/Python/Python-ast.c	Mon Jun 27 16:51:08 2011 +0200
++++ b/Python/Python-ast.c	Mon Jun 27 17:00:20 2011 +0200
 @@ -205,6 +205,7 @@
  };
  static PyTypeObject *Yield_type;
                  if (*out == NULL) goto failed;
                  return 0;
          }
-diff -r 7765c3f79e47 Python/graminit.c
---- a/Python/graminit.c	Fri Jun 17 22:00:44 2011 +0200
-+++ b/Python/graminit.c	Fri Jun 17 22:06:32 2011 +0200
+diff -r 8720ab7944b4 Python/graminit.c
+--- a/Python/graminit.c	Mon Jun 27 16:51:08 2011 +0200
++++ b/Python/graminit.c	Mon Jun 27 17:00:20 2011 +0200
 @@ -1700,29 +1700,36 @@
      {1, arcs_74_6},
      {2, arcs_74_7},
 +    {170, labels},
      256
  };
-diff -r 7765c3f79e47 Python/opcode_targets.h
---- a/Python/opcode_targets.h	Fri Jun 17 22:00:44 2011 +0200
-+++ b/Python/opcode_targets.h	Fri Jun 17 22:06:32 2011 +0200
+diff -r 8720ab7944b4 Python/opcode_targets.h
+--- a/Python/opcode_targets.h	Mon Jun 27 16:51:08 2011 +0200
++++ b/Python/opcode_targets.h	Mon Jun 27 17:00:20 2011 +0200
 @@ -71,7 +71,7 @@
      &&TARGET_STORE_LOCALS,
      &&TARGET_PRINT_EXPR,