-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Open
Labels
Description
There is a well-defined binary interface between top-level functions such as fmt::format and their type-erased counterparts like fmt::vformat. This interface relies only on basic C++ features and should be compatible with C (except for the overload returning std::string obviously). As a result, it may be possible to provide a C API that builds argument lists using _Generic and invokes the type-erased functions.
Unlike the printf family of functions, such an API could be fully type-safe, including for runtime format strings, and would not rely on encoding type information in the format string itself.
This issue is opened to gauge interest. React with a 👍 or another emoji if you would use this.
Reactions are currently unavailable