diff options
author | Victor Shepelev <zverok.offline@gmail.com> | 2020-12-21 02:32:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-21 09:32:30 +0900 |
commit | 5253b9579a129f66a768dae24bd50a95bab02841 (patch) | |
tree | 289b20b4430e3368a9047a94f2e829679b013c02 /NEWS.md | |
parent | 6be61ab264c98c96e26b5d3398cf80b49197ba29 (diff) |
Document usage of ArithmeticSequence in Array#slice, and add to NEWS (#3952)
Notes
Notes:
Merged-By: mrkn <mrkn@ruby-lang.org>
Diffstat (limited to 'NEWS.md')
-rw-r--r-- | NEWS.md | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -149,6 +149,14 @@ Outstanding ones only. * Array#uniq * Array#* + * Can be sliced with Enumerator::ArithmeticSequence + + ```ruby + dirty_data = ['--', 'data1', '--', 'data2', '--', 'data3'] + dirty_data[(1..).step(2)] # take each second element + # => ["data1", "data2", "data3"] + ``` + * ConditionVariable * ConditionVariable#wait may now invoke the `block`/`unblock` scheduler |