1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/scanf.rb (Scanf::FormatSpecifier#initialize): %i should accept

single digit decimal.  [ruby-core:18355]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18744 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2008-08-20 21:12:58 +00:00
parent e1ebab4ed0
commit b9e3f3c129
3 changed files with 8 additions and 3 deletions

View file

@ -357,7 +357,7 @@ module Scanf
# %i
when /%\*?i/
[ "([-+]?(?:(?:0[0-7]+)|(?:0[Xx]#{h}+)|(?:[1-9]\\d+)))", :extract_integer ]
[ "([-+]?(?:(?:0[0-7]+)|(?:0[Xx]#{h}+)|(?:[1-9]\\d*)))", :extract_integer ]
# %5i
when /%\*?(\d+)i/