logoalt Hacker News

throwawaymathslast Tuesday at 8:05 PM1 replyview on HN

have a single return value and if you really need MRV, return as a tuple type, which you could destructure.

(this is what zig does)


Replies

9rxlast Tuesday at 8:16 PM

But then why accept multiple input arguments? Why not limit to a single argument, accepting a tuple where multiple arguments are necessary, for input too?

Where multiple input arguments are present, not having multiple output arguments is just strange.

show 1 reply