Actions
Bug #13336
closedDefault Parameters don't work
Bug #13336:
Default Parameters don't work
Description
Files
Actions
Added by herbert.bonaffini@gmail.com (Herbert Bonaffini) over 9 years ago. Updated almost 8 years ago.
Description
Files
| hello_bug.rb (132 Bytes) hello_bug.rb | herbert.bonaffini@gmail.com (Herbert Bonaffini), 03/20/2017 05:31 PM |
mame-san: what do you think about it?
This is intended. If a method accepts keyword arguments and if its last argument is a hash object, it is considered for keyword arguments. If you want to pass a hash as the first parameter, you need to explicitly pass a hash for keyword arguments, i.e., funny({k: 1}, {}).
This is a duplicate of #12717, so closing this.