[Variadics are a topic where people seem to be quite passionate about, but I'm absolutely convinced that the current implementation really doesn't pull it's own weight, and you just discovered another quirk]
Afaik, variadics are a type on their own - and they are very special:
You can only use them in one single place (method signature), and they magically turn into arrays when they are used.
Therefor, you cannot initialize a variadic argument with an array (and the syntax without []
isn't allowed either.
There's a very simple solution to this and other issues, but people seem to love some special cases like this
See [Discussion] Variadics as an Attribute or search for variadics (there are many threads about the topic).
Basically, it's about getting rid of the special syntax and turn variadics into pure sugar for arguments that can be initialized with an array literal (that would be more than just arrays, which is one of the many benefits of this approach)