[前][次][番号順一覧][スレッド一覧]

ruby-changes:29326

From: nobu <ko1@a...>
Date: Tue, 18 Jun 2013 16:43:59 +0900 (JST)
Subject: [ruby-changes:29326] nobu:r41378 (trunk): parse.y: clear lex_strterm

nobu	2013-06-18 16:43:47 +0900 (Tue, 18 Jun 2013)

  New Revision: 41378

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=41378

  Log:
    parse.y: clear lex_strterm
    
    * parse.y (parser_heredoc_restore): clear lex_strterm always to get
      rid of marking recycled node.  this bug is revealed by r41372 with
      GC.stress=true.

  Modified files:
    trunk/ChangeLog
    trunk/parse.y

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 41377)
+++ ChangeLog	(revision 41378)
@@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Jun 18 16:43:44 2013  Nobuyoshi Nakada  <nobu@r...>
+
+	* parse.y (parser_heredoc_restore): clear lex_strterm always to get
+	  rid of marking recycled node.  this bug is revealed by r41372 with
+	  GC.stress=true.
+
 Tue Jun 18 12:53:25 2013  Tanaka Akira  <akr@f...>
 
 	* bignum.c (nlz): Cast the result explicitly.
Index: parse.y
===================================================================
--- parse.y	(revision 41377)
+++ parse.y	(revision 41378)
@@ -6345,6 +6345,7 @@ parser_heredoc_restore(struct parser_par https://github.com/ruby/ruby/blob/trunk/parse.y#L6345
 {
     VALUE line;
 
+    lex_strterm = 0;
     line = here->nd_orig;
     lex_lastline = line;
     lex_pbeg = RSTRING_PTR(line);
@@ -6419,7 +6420,6 @@ parser_here_document(struct parser_param https://github.com/ruby/ruby/blob/trunk/parse.y#L6420
 #endif
       restore:
 	heredoc_restore(lex_strterm);
-	lex_strterm = 0;
 	return 0;
     }
     if (was_bol() && whole_match_p(eos, len, indent)) {

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]