diff options
author | Yves Senn <yves.senn@gmail.com> | 2014-01-08 11:20:56 +0100 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2014-01-08 11:27:43 +0100 |
commit | a03fed88f780922e3a3ab7b22af945f29a711ae4 (patch) | |
tree | 40773043da47196d92e5ac49cdaf0dda59b3ce02 /guides/w3c_validator.rb | |
parent | 40a83d740fafddcb3cad3b2c2dbfa3c446338d12 (diff) | |
download | rails-a03fed88f780922e3a3ab7b22af945f29a711ae4.tar.gz rails-a03fed88f780922e3a3ab7b22af945f29a711ae4.tar.bz2 rails-a03fed88f780922e3a3ab7b22af945f29a711ae4.zip |
Revert "Speedup String#to"
This reverts commit 2ef1fb2c455ca53a0c1e1768f50824926ce28bd3.
As described in PR #13627 this commit broke functionality when passing
a negative Fixnum to the `String#to` method:
```ruby
assert_equal "hell", s.to(-2)
```
Before the revert, this failed with:
```
1) Failure:
StringAccessTest#test_#to_with_negative_Fixnum,_position_is_counted_from_the_end [test/core_ext/string_ext_test.rb:275]:
Expected: "hell"
Actual: nil
```
This revert is to keep the functionality on `master` working.
If there is another way to get the performance benefit and keep
the documented functionality we can add that.
/cc @amatsuda @carlosantoniodasilva
Diffstat (limited to 'guides/w3c_validator.rb')
0 files changed, 0 insertions, 0 deletions