3 ms·
Why would you have %s tied to a string type instead of having it print anything? The type should not be coming from the format string but be inferred from the
by kazinator 2y ago
Why would you have %s tied to a string type instead of having it print anything?
The type should not be coming from the format string but be inferred from the arguments that are being combined with that string. Of course certain conversion specifiers in the format string only makes sense for numbers.
- o11c 2y agoIf you have type checking but not named arguments, it provides a fair degree of sanity checking. And as much as named arguments are nice from a user perspective, they do have significant runtime overhead if the format string can be localized.