Permalink
Browse files

AS guide: details how a corner case behaves in different Ruby versions

  • Loading branch information...
1 parent 6aa959e commit d768f7415eab526a746fab07e04fe664ff31f231 @fxn fxn committed Sep 22, 2009
Showing with 2 additions and 2 deletions.
  1. +2 −2 railties/guides/source/active_support_overview.textile
@@ -747,7 +747,7 @@ Returns the character of the string at position +position+:
"hello".at(0) # => "h"
"hello".at(4) # => "o"
"hello".at(-1) # => "o"
-"hello".at(10) # => ERROR
+"hello".at(10) # => ERROR if < 1.9, nil in 1.9
</ruby>
h5. +from(position)+
@@ -758,7 +758,7 @@ Returns the substring of the string starting at position +position+:
"hello".from(0) # => "hello"
"hello".from(2) # => "llo"
"hello".from(-2) # => "lo"
-"hello".from(10) # => ""
+"hello".from(10) # => "" if < 1.9, nil in 1.9
</ruby>
h5. +to(position)+

0 comments on commit d768f74

Please sign in to comment.