in reply to What is the + in +shift doing here?
It's not necessary in this case. But in the following case, it would:
Without the +, it's equivalent to:sub get {$some_hash{+shift}->("get",@_)}
but with the +, it's equivalent to:sub get {$some_hash{"shift"}->("get",@_)}
But that's more typing.sub get {$some_hash{shift(@_)}->("get",@_)}
|
|---|