How to know what will be executed when only one parameter is received?
You read the spec that explains how overload resolution is handled. From section 7.5.3.2, the corresponding paragraph indicates:
Otherwise, if M P is applicable in its normal form, and M Q has an array of params and is applicable only in its expanded form, then M P is better than M Q.
Thus, a version that does not require expansion of the parameter array (your single-line version) is selected at compile time instead of the version of the parameter array.
source share