Given the following method, which takes two arguments from the begin and end :
def make_range(begin: 0, end: -1)
I can call this method without problems:
make_range(begin: 2, end: 4)
But how to use keyword arguments when implementing a method, given that both of them are Ruby keywords ?
This clearly does not work:
def make_range(begin: 0, end: -1) begin..end end
Please note that this is just an example, the problem applies to all keywords, not just begin and end .
source share