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

ruby-changes:26386

From: drbrain <ko1@a...>
Date: Tue, 18 Dec 2012 11:48:46 +0900 (JST)
Subject: [ruby-changes:26386] drbrain:r38437 (trunk): * doc/syntax/literals.rdoc: Added 0o octal integers.

drbrain	2012-12-18 11:48:35 +0900 (Tue, 18 Dec 2012)

  New Revision: 38437

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

  Log:
    * doc/syntax/literals.rdoc:  Added 0o octal integers.

  Modified files:
    trunk/ChangeLog
    trunk/doc/syntax/literals.rdoc

Index: doc/syntax/literals.rdoc
===================================================================
--- doc/syntax/literals.rdoc	(revision 38436)
+++ doc/syntax/literals.rdoc	(revision 38437)
@@ -45,8 +45,10 @@ point numbers as well. https://github.com/ruby/ruby/blob/trunk/doc/syntax/literals.rdoc#L45
 
 You can also write numbers in hexadecimal, octal or binary formats.  For
 hexadecimal numbers use a prefix of <tt>0x</tt>, for octal numbers use a
-prefix of <tt>0</tt>, for binary numbers use a prefix of <tt>0b</tt>.  The
-alphabetic component of the number is not case-sensitive.  Examples:
+prefix of <tt>0</tt> or <tt>0o</tt>, for binary numbers use a prefix of
+<tt>0b</tt>.  The alphabetic component of the number is not case-sensitive.
+
+Examples:
 
   0xaa
   0xAa
@@ -56,6 +58,8 @@ alphabetic component of the number is no https://github.com/ruby/ruby/blob/trunk/doc/syntax/literals.rdoc#L58
   0XaA
 
   0252
+  0o252
+  0O252
 
   0b10101010
   0B10101010
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 38436)
+++ ChangeLog	(revision 38437)
@@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Tue Dec 18 11:45:26 2012  Eric Hodel  <drbrain@s...>
+
+	* doc/syntax/literals.rdoc:  Added 0o octal integers.
+
 Tue Dec 18 12:28:52 2012  Martin Bosslet  <Martin.Bosslet@g...>
 
 	* test/openssl/test_ssl.rb: Use :TLSv1_2_client explicitly in

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

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