From 9d3a9e97c0399a3d9e12db677ab974240dd57a57 Mon Sep 17 00:00:00 2001 From: nagachika Date: Sat, 23 May 2015 18:35:37 +0000 Subject: [PATCH] merge revision(s) 50406,50407: [Backport #11075] * rational.c: Added documentation for rational literal. [Bug #11075][fix GH-885][ci skip] Patch by @shishir127 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@50627 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ rational.c | 5 +++-- version.h | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 10d93ad2dc..3d6ae81a9f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun May 24 03:32:53 2015 SHIBATA Hiroshi + + * rational.c: Added documentation for rational literal. + [Bug #11075][fix GH-885][ci skip] Patch by @shishir127 + Sun May 24 03:06:20 2015 Nobuyoshi Nakada * ext/socket/ipsocket.c (init_inetsock_internal): preserve errno diff --git a/rational.c b/rational.c index addb195e81..134db642c1 100644 --- a/rational.c +++ b/rational.c @@ -2465,13 +2465,14 @@ nurat_s_convert(int argc, VALUE *argv, VALUE klass) * a/b (b>0). Where a is numerator and b is denominator. Integer a * equals rational a/1 mathematically. * - * In ruby, you can create rational object with Rational, to_r or - * rationalize method. The return values will be irreducible. + * In ruby, you can create rational object with Rational, to_r, + * rationalize method or suffixing r to a literal. The return values will be irreducible. * * Rational(1) #=> (1/1) * Rational(2, 3) #=> (2/3) * Rational(4, -6) #=> (-2/3) * 3.to_r #=> (3/1) + * 2/3r #=> (2/3) * * You can also create rational object from floating-point numbers or * strings. diff --git a/version.h b/version.h index 6133eb0106..7e2856363b 100644 --- a/version.h +++ b/version.h @@ -1,6 +1,6 @@ #define RUBY_VERSION "2.2.3" #define RUBY_RELEASE_DATE "2015-05-24" -#define RUBY_PATCHLEVEL 123 +#define RUBY_PATCHLEVEL 124 #define RUBY_RELEASE_YEAR 2015 #define RUBY_RELEASE_MONTH 5