We can use # operator to concatenate strings, but it can be too
tedious sometimes and we can't use it to concatenate code strings.
A new bang operator !format is added to format strings (very limited
currently).
!format("{0} {1} ...", arg0, arg1, ...)
Its first operand is a format string, and followings are several
operands (can be none) to format. Currently, {i} where i is the
i-th format argument is the only placeholder format we support.
This bang operator can be used to format code string, which can
reduce a lot of duplicated code.
See D156432 for usages.
This is really nitpicking. You allow (and I think it is correct) invocations without *args*:
... so maybe replace this with the suggestion? This is how it is done for printf-like variadic functions: https://en.cppreference.com/w/c/io/fprintf