Replies: 1 comment 1 reply
-
Hi @denfren 👋 Good question, it would seem natural for The current rule for varargs is simple but limited, the varargs get rolled into a tuple, and then it's passed around as a regular non-magic value. It would be possible to introduce an unpacking operator, reusing
It would be a very niche feature but might be the only way to make it possible to call a variadic function from another variadic function.. In your example there's the workaround of looping over the varargs, but that only works given that
But if you could only call it once then there wouldn't be a way to pass the varargs along:
So I think this simply is a missing feature. |
Beta Was this translation helpful? Give feedback.
-
Can tuples be unpacked, so that varargs can be passed on?
Beta Was this translation helpful? Give feedback.
All reactions