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

ruby-changes:31679

From: nobu <ko1@a...>
Date: Thu, 21 Nov 2013 18:28:51 +0900 (JST)
Subject: [ruby-changes:31679] nobu:r43758 (trunk): tempfile.rb: get rid of warnings

nobu	2013-11-21 18:28:43 +0900 (Thu, 21 Nov 2013)

  New Revision: 43758

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

  Log:
    tempfile.rb: get rid of warnings
    
    * lib/tempfile.rb (Tempfile#initialize): use class method to get rid
      of warnings when $VERBOSE.

  Modified files:
    trunk/ChangeLog
    trunk/lib/tempfile.rb
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 43757)
+++ ChangeLog	(revision 43758)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Thu Nov 21 18:28:42 2013  Nobuyoshi Nakada  <nobu@r...>
+
+	* lib/tempfile.rb (Tempfile#initialize): use class method to get rid
+	  of warnings when $VERBOSE.
+
 Thu Nov 21 17:43:29 2013  Koichi Sasada  <ko1@a...>
 
 	* gc.c: rename initial_xxx variables to gc_params.xxx.
Index: lib/tempfile.rb
===================================================================
--- lib/tempfile.rb	(revision 43757)
+++ lib/tempfile.rb	(revision 43758)
@@ -133,7 +133,7 @@ class Tempfile < DelegateClass(File) https://github.com/ruby/ruby/blob/trunk/lib/tempfile.rb#L133
     @clean_proc = Remover.new(@data)
     ObjectSpace.define_finalizer(self, @clean_proc)
 
-    create(basename, *rest) do |tmpname, n, opts|
+    ::Dir::Tmpname.create(basename, *rest) do |tmpname, n, opts|
       mode = File::RDWR|File::CREAT|File::EXCL
       perm = 0600
       if opts

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

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