Actions
Feature #16045
closedCalling functions with keyword arguments
Status:
Rejected
Assignee:
-
Target version:
-
Description
Python:
def fn(a=1,b=2,c=3):
print(a,b,c)
fn() # 1 2 3
fn(c=4) # 1 2 4
Ruby:
def fn(a=1, b=2, c=3)
p a,b,c
end
fn(c=4) # 4 2 3
A very convenient and necessary thing that you must add in Ruby!?
Updated by shyouhei (Shyouhei Urabe) over 5 years ago
- Status changed from Open to Rejected
Updated by D1mon (Dim F) over 5 years ago
def fn(a:1,b:2,c:3)
p a,b,c
end
fn(c:4) # 1 2 4
did not know. can close
Actions
Like0
Like0Like0