[Python-checkins] python/dist/src/Python ast.c,1.1.2.52,1.1.2.53

jhylton at users.sourceforge.net jhylton at users.sourceforge.net
Fri Apr 23 14:25:30 EDT 2004


Update of /cvsroot/python/python/dist/src/Python
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4908

Modified Files:
      Tag: ast-branch
	ast.c 
Log Message:
Fix bugs in complex arguments.  

Was passing the '(' from fplist instead of 'fpdef'.


Index: ast.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/Attic/ast.c,v
retrieving revision 1.1.2.52
retrieving revision 1.1.2.53
diff -C2 -d -r1.1.2.52 -r1.1.2.53
*** ast.c	23 Apr 2004 15:27:53 -0000	1.1.2.52
--- ast.c	23 Apr 2004 18:25:26 -0000	1.1.2.53
***************
*** 492,499 ****
--- 492,502 ----
  {
      int i, len = (NCH(n) + 1) / 2;
+     expr_ty result;
      asdl_seq *args = asdl_seq_new(len);
      if (!args)
          return NULL;
  
+     REQ(n, fplist);
+ 
      for (i = 0; i < len; i++) {
          const node *child = CHILD(CHILD(n, 2*i), 0);
***************
*** 502,510 ****
              arg = Name(NEW_IDENTIFIER(child), Store);
          else
!             arg = compiler_complex_args(child);
          asdl_seq_SET(args, i, arg);
      }
  
!     return Tuple(args, Store);
  }
  
--- 505,516 ----
              arg = Name(NEW_IDENTIFIER(child), Store);
          else
!             arg = compiler_complex_args(CHILD(CHILD(n, 2*i), 1));
! 	set_context(arg, Store, n);
          asdl_seq_SET(args, i, arg);
      }
  
!     result = Tuple(args, Store);
!     set_context(result, Store, n);
!     return result;
  }
  




More information about the Python-checkins mailing list