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

ruby-changes:25717

From: kosaki <ko1@a...>
Date: Wed, 21 Nov 2012 01:00:19 +0900 (JST)
Subject: [ruby-changes:25717] kosaki:r37774 (trunk): * file.c (Init_File): null device definition uses rb_define_const

kosaki	2012-11-21 01:00:04 +0900 (Wed, 21 Nov 2012)

  New Revision: 37774

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

  Log:
    * file.c (Init_File): null device definition uses rb_define_const
      instead of rb_file_const.

  Modified files:
    trunk/ChangeLog
    trunk/file.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 37773)
+++ ChangeLog	(revision 37774)
@@ -1,3 +1,8 @@
+Wed Nov 21 00:57:43 2012  KOSAKI Motohiro  <kosaki.motohiro@g...>
+
+	* file.c (Init_File): null device definition uses rb_define_const
+	  instead of rb_file_const.
+
 Wed Nov 21 00:28:18 2012  NARUSE, Yui  <naruse@r...>
 
 	* test/ruby/test_m17n_comb.rb (test_str_crypt): Use RbConfig to get
Index: file.c
===================================================================
--- file.c	(revision 37773)
+++ file.c	(revision 37774)
@@ -5601,11 +5601,8 @@
     /* non-blocking lock. used with LOCK_SH or LOCK_EX. see File#flock  */
     rb_define_const(rb_mFConst, "LOCK_NB", INT2FIX(LOCK_NB));
 
-    /* Document-const: NULL
-     *
-     * Name of the null device
-     */
-    rb_file_const("NULL", rb_obj_freeze(rb_usascii_str_new2(null_device)));
+    /* Name of the null device */
+    rb_define_const(rb_mFConst, "NULL", rb_obj_freeze(rb_usascii_str_new2(null_device)));
 
     rb_define_method(rb_cFile, "path",  rb_file_path, 0);
     rb_define_method(rb_cFile, "to_path",  rb_file_path, 0);

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

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