diff options
author | Kazuki Tsujimoto <kazuki@callcc.net> | 2020-06-14 09:24:36 +0900 |
---|---|---|
committer | Kazuki Tsujimoto <kazuki@callcc.net> | 2020-06-14 09:24:36 +0900 |
commit | ddded1157a90d21cb54b9f07de35ab9b4cc472e1 (patch) | |
tree | 315005f4eead6840846e6ce4bbd4dfa44c3bfce7 /NEWS.md | |
parent | f7906a7e31e6b1cfa135ecea69deb8827e8c8803 (diff) | |
download | ruby-ddded1157a90d21cb54b9f07de35ab9b4cc472e1.tar.gz |
Introduce find pattern [Feature #16828]
Diffstat (limited to 'NEWS.md')
-rw-r--r-- | NEWS.md | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -38,6 +38,18 @@ sufficient information, see the ChangeLog file or Redmine instead of a warning. yield in a class definition outside of a method is now a SyntaxError instead of a LocalJumpError. [[Feature #15575]] +* Find pattern is added. [[Feature #16828]] + + ```ruby + case ["a", 1, "b", "c", 2, "d", "e", "f", 3] + in [*pre, String => x, String => y, *post] + p pre #=> ["a", 1] + p x #=> "b" + p y #=> "c" + p post #=> [2, "d", "e", "f", 3] + end + ``` + * Rightward assignment statement is added. [EXPERIMENTAL] [[Feature #15921]] |