Hi,
It would useful to allow the __format__ attribute on non-variadic
functions. For example:
template<typename... Arguments>
__attribute__ ((__format__ (__printf__, 1, 2)))
inline auto format(const char *Fmt, Arguments&&... Args) {
return format_object<Arguments...>(Fmt, std::forward<Arguments>(Args)...);
}
When I try to compile this with clang I get error: "format attribute
requires variadic function".
Is there any reason why this shouldn't be allowed?
Thanks,
Kal