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

ruby-changes:14649

From: yugui <ko1@a...>
Date: Sat, 30 Jan 2010 22:06:41 +0900 (JST)
Subject: [ruby-changes:14649] Ruby:r26496 (ruby_1_9_1): merges r25402,r25404,r25405,r25406 and r25407 from trunk into ruby_1_9_1.

yugui	2010-01-30 21:51:12 +0900 (Sat, 30 Jan 2010)

  New Revision: 26496

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

  Log:
    merges r25402,r25404,r25405,r25406 and r25407 from trunk into ruby_1_9_1.
    --
    * parse.y (parser_here_document): dispatch delayed heredoc
      contents.  based on a patch from Andy Keep in [ruby-core:24855].
    --
    * parse.y (mlhs_basic): fixed handling splat in middle of mlhs.  a
      patch from Andy Keep in [ruby-core:26163]
    --
    * parse.y (method_call): dispatch symbols.  a patch from Andy Keep in
      [ruby-core:26169].  [ruby-core:26165]
    --
    * test/ripper/test_*.rb: fixed indent.
    --
    * parse.y (ripper_intern): enable literal optimization.

  Modified files:
    branches/ruby_1_9_1/ChangeLog
    branches/ruby_1_9_1/parse.y
    branches/ruby_1_9_1/test/ripper/test_files.rb
    branches/ruby_1_9_1/test/ripper/test_filter.rb
    branches/ruby_1_9_1/test/ripper/test_parser_events.rb
    branches/ruby_1_9_1/test/ripper/test_scanner_events.rb
    branches/ruby_1_9_1/version.h

Index: ruby_1_9_1/ChangeLog
===================================================================
--- ruby_1_9_1/ChangeLog	(revision 26495)
+++ ruby_1_9_1/ChangeLog	(revision 26496)
@@ -1,3 +1,16 @@
+Tue Oct 20 15:38:02 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* parse.y (ripper_intern): enable literal optimization.
+
+	* parse.y (method_call): dispatch symbols.  a patch from Andy Keep in
+	  [ruby-core:26169].  [ruby-core:26165]
+
+	* parse.y (mlhs_basic): fixed handling splat in middle of mlhs.  a
+	  patch from Andy Keep in [ruby-core:26163]
+
+	* parse.y (parser_here_document): dispatch delayed heredoc
+	  contents.  based on a patch from Andy Keep in [ruby-core:24855].
+
 Sat Jan 30 18:09:36 2010  Yuki Sonoda (Yugui)  <yugui@y...>
 
 	* vm_method.c (rb_alias): treats an alias as if it is a newly defined
Index: ruby_1_9_1/parse.y
===================================================================
--- ruby_1_9_1/parse.y	(revision 26495)
+++ ruby_1_9_1/parse.y	(revision 26496)
@@ -515,7 +515,7 @@
 
 #define yyparse ripper_yyparse
 
-static VALUE ripper_intern(const char*);
+#define ripper_intern(s) ID2SYM(rb_intern(s))
 static VALUE ripper_id2sym(ID);
 #ifdef __GNUC__
 #define ripper_id2sym(id) ((id) < 256 && rb_ispunct(id) ? \
@@ -10205,12 +10205,6 @@
     return ID2SYM(rb_intern(name));
 }
 
-static VALUE
-ripper_intern(const char *s)
-{
-    return ID2SYM(rb_intern(s));
-}
-
 static ID
 ripper_get_id(VALUE v)
 {
Index: ruby_1_9_1/version.h
===================================================================
--- ruby_1_9_1/version.h	(revision 26495)
+++ ruby_1_9_1/version.h	(revision 26496)
@@ -1,5 +1,5 @@
 #define RUBY_VERSION "1.9.1"
-#define RUBY_PATCHLEVEL 401
+#define RUBY_PATCHLEVEL 402
 #define RUBY_VERSION_MAJOR 1
 #define RUBY_VERSION_MINOR 9
 #define RUBY_VERSION_TEENY 1
Index: ruby_1_9_1/test/ripper/test_parser_events.rb
===================================================================
--- ruby_1_9_1/test/ripper/test_parser_events.rb	(revision 26495)
+++ ruby_1_9_1/test/ripper/test_parser_events.rb	(revision 26496)
@@ -1,9 +1,11 @@
 begin
+  require_relative 'dummyparser'
+  require_relative '../ruby/envutil'
+  require 'test/unit'
+  ripper_test = true
+rescue LoadError
+end
 
-require_relative 'dummyparser'
-require_relative '../ruby/envutil'
-require 'test/unit'
-
 class TestRipper_ParserEvents < Test::Unit::TestCase
 
   # should be enabled
@@ -624,7 +626,4 @@
                         ["[fcall(proc,[],&block([],[void()]))]"], [], '[ruby-dev:39423]')
     end
   end
-end
-
-rescue LoadError
-end
+end if ripper_test
Index: ruby_1_9_1/test/ripper/test_files.rb
===================================================================
--- ruby_1_9_1/test/ripper/test_files.rb	(revision 26495)
+++ ruby_1_9_1/test/ripper/test_files.rb	(revision 26496)
@@ -1,9 +1,11 @@
 begin
+  require 'ripper'
+  require 'find'
+  require 'test/unit'
+  ripper_test = true
+rescue LoadError
+end
 
-require 'ripper'
-require 'find'
-require 'test/unit'
-
 class TestRipper_Generic < Test::Unit::TestCase
   SRCDIR = File.dirname(File.dirname(File.dirname(File.expand_path(__FILE__))))
 
@@ -18,8 +20,4 @@
       assert_nothing_raised("ripper failed to parse: #{n.inspect}") { Parser.new(File.read(n)).parse }
     }
   end
-end
-
-rescue LoadError
-end
-  
+end if ripper_test
Index: ruby_1_9_1/test/ripper/test_filter.rb
===================================================================
--- ruby_1_9_1/test/ripper/test_filter.rb	(revision 26495)
+++ ruby_1_9_1/test/ripper/test_filter.rb	(revision 26496)
@@ -1,8 +1,10 @@
 begin
+  require 'ripper'
+  require 'test/unit'
+  ripper_test = true
+rescue LoadError
+end
 
-require 'ripper'
-require 'test/unit'
-
 class TestRipper_Filter < Test::Unit::TestCase
 
   class Filter < Ripper::Filter
@@ -48,7 +50,4 @@
     Filter.new(File.read(filename)).parse(data)
     assert_equal("begin", data[:token])
   end
-end
-
-rescue LoadError
-end
+end if ripper_test
Index: ruby_1_9_1/test/ripper/test_scanner_events.rb
===================================================================
--- ruby_1_9_1/test/ripper/test_scanner_events.rb	(revision 26495)
+++ ruby_1_9_1/test/ripper/test_scanner_events.rb	(revision 26496)
@@ -2,10 +2,12 @@
 # test_scanner_events.rb
 #
 begin
+  require 'ripper'
+  require 'test/unit'
+  ripper_test = true
+rescue LoadError
+end
 
-require 'ripper'
-require 'test/unit'
-
 class TestRipper_ScannerEvents < Test::Unit::TestCase
 
   def test_event_coverage
@@ -806,7 +808,4 @@
   def test_tlambda_arg
   end
 
-end
-
-rescue LoadError
-end
+end if ripper_test

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

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