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

ruby-changes:23805

From: drbrain <ko1@a...>
Date: Fri, 1 Jun 2012 06:42:35 +0900 (JST)
Subject: [ruby-changes:23805] drbrain:r35856 (trunk): * object.c (Init_Object): Restored Kernel documentation based on

drbrain	2012-06-01 06:41:21 +0900 (Fri, 01 Jun 2012)

  New Revision: 35856

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

  Log:
    * object.c (Init_Object):  Restored Kernel documentation based on
      Pickaxe book documentation.  Patch by Zachary Scott.
      [ruby-trunk - Feature #6521]

  Modified files:
    trunk/ChangeLog
    trunk/object.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 35855)
+++ ChangeLog	(revision 35856)
@@ -1,3 +1,9 @@
+Fri Jun  1 06:40:25 2012  Eric Hodel  <drbrain@s...>
+
+	* object.c (Init_Object):  Restored Kernel documentation based on
+	  Pickaxe book documentation.  Patch by Zachary Scott.
+	  [ruby-trunk - Feature #6521]
+
 Fri Jun  1 06:29:42 2012  Eric Hodel  <drbrain@s...>
 
 	* object.c (rb_equal):  Let Object be a link in #=== documentation.
Index: object.c
===================================================================
--- object.c	(revision 35855)
+++ object.c	(revision 35856)
@@ -2845,6 +2845,18 @@
     rb_define_private_method(rb_cBasicObject, "singleton_method_removed", rb_obj_dummy, 1);
     rb_define_private_method(rb_cBasicObject, "singleton_method_undefined", rb_obj_dummy, 1);
 
+    /* Document-module: Kernel
+     *
+     * The Kernel module is included by class Object, so its methods are
+     * available in every Ruby object.
+     *
+     * The Kernel instance methods are documented in class Object while the
+     * module methods are documented here.  These methods are called without a
+     * receiver and thus can be called in functional form:
+     *
+     *   sprintf "%.1f", 1.234 #=> "1.2"
+     *
+     */
     rb_mKernel = rb_define_module("Kernel");
     rb_include_module(rb_cObject, rb_mKernel);
     rb_define_private_method(rb_cClass, "inherited", rb_obj_dummy, 1);

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

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