diff options
| author | KOBAYASHI Shuji <[email protected]> | 2019-08-30 15:46:29 +0900 |
|---|---|---|
| committer | KOBAYASHI Shuji <[email protected]> | 2019-09-02 08:58:33 +0900 |
| commit | 66211394e1597e403f14aada81a993f5b1429066 (patch) | |
| tree | 105373cb13dccf72c8fcd90a496a21c1da9b5b5f /src/string.c | |
| parent | 0ce1878abafcaa84e373de144480aaadfff3039b (diff) | |
| download | mruby-66211394e1597e403f14aada81a993f5b1429066.tar.gz mruby-66211394e1597e403f14aada81a993f5b1429066.zip | |
`Enumerator::Chain#rewind` shouldn't rewind elements aren't iterated
### Example:
```ruby
# example.rb
e = [1]
def e.rewind; p :r end
c = e.chain(e)
c.each{break c}.rewind
```
#### Before this patch:
```terminal
$ bin/mruby example.rb
:r
:r
```
#### After this patch (same as Ruby):
```terminal
$ bin/mruby example.rb
:r
```
Diffstat (limited to 'src/string.c')
0 files changed, 0 insertions, 0 deletions
