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

ruby-changes:15211

From: knu <ko1@a...>
Date: Mon, 29 Mar 2010 21:49:02 +0900 (JST)
Subject: [ruby-changes:15211] Ruby:r27092 (trunk): * prelude.rb, .document: Stuff in prelude.rb should be documented

knu	2010-03-29 21:48:43 +0900 (Mon, 29 Mar 2010)

  New Revision: 27092

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

  Log:
    * prelude.rb, .document: Stuff in prelude.rb should be documented
      as well.

  Modified files:
    trunk/.document
    trunk/ChangeLog
    trunk/prelude.rb

Index: prelude.rb
===================================================================
--- prelude.rb	(revision 27091)
+++ prelude.rb	(revision 27092)
@@ -1,7 +1,9 @@
-
-# Mutex
-
 class Mutex
+  # call-seq:
+  #    mutex.synchronize { ... }
+  #
+  # Obtains a lock, runs the block, and releases the lock when the
+  # block completes.  See the example under Mutex.
   def synchronize
     self.lock
     begin
@@ -12,10 +14,16 @@
   end
 end
 
-# Thread
-
 class Thread
+  # :nodoc:
   MUTEX_FOR_THREAD_EXCLUSIVE = Mutex.new
+
+  # call-seq:
+  #    Thread.exclusive { block }   => obj
+  #  
+  # Wraps a block in Thread.critical, restoring the original value
+  # upon exit from the critical section, and returns the value of the
+  # block.
   def self.exclusive
     MUTEX_FOR_THREAD_EXCLUSIVE.synchronize{
       yield
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 27091)
+++ ChangeLog	(revision 27092)
@@ -1,3 +1,8 @@
+Mon Mar 29 21:47:44 2010  Akinori MUSHA  <knu@i...>
+
+	* prelude.rb, .document: Stuff in prelude.rb should be documented
+	  as well.
+
 Mon Mar 29 20:23:05 2010  Keiju Ishitsuka  <keiju@r...>
 
 	* lib/matrix.rb(Vector#each2, Vector#collect2): add type check for
Index: .document
===================================================================
--- .document	(revision 27091)
+++ .document	(revision 27092)
@@ -6,6 +6,9 @@
 # Process all the C source files
 *.c
 
+# prelude
+prelude.rb
+
 # the lib/ directory (which has its own .document file)
 
 lib

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

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