mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00
[DOC] Fix typo in docs of Regexp#deconstruct_keys
of => if
This commit is contained in:
parent
5bbb6fd6c3
commit
3467355450
1 changed files with 1 additions and 1 deletions
2
re.c
2
re.c
|
@ -2390,7 +2390,7 @@ match_named_captures(int argc, VALUE *argv, VALUE match)
|
|||
* m.deconstruct_keys([:hours, :minutes]) # => {:hours => "18", :minutes => "37"}
|
||||
* m.deconstruct_keys(nil) # => {:hours => "18", :minutes => "37", :seconds => "22"}
|
||||
*
|
||||
* Returns an empty hash of no named captures were defined:
|
||||
* Returns an empty hash if no named captures were defined:
|
||||
*
|
||||
* m = /(\d{2}):(\d{2}):(\d{2})/.match("18:37:22")
|
||||
* m.deconstruct_keys(nil) # => {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue