
Mathias Gaunard wrote:
Ion GaztaƱaga wrote:
-> Hard formatting: printf/scanf are much easier to use and they don't need several hundred of function calls to do their job. The operator<< overloading is also a problem if each call needs some internal locking. A formatting syntax that can minimize the locking needs would be a good choice. I would be really happy with a type-safe printf (variadic templates to the rescue).
Something that would use meta-programming to optimize the generation of the formatted string would be way better than printf. How does this improve on printf ? Not that I favor printf but I dont see how this is any better. Speed wise yea much better at run time at least, printf is a hog on cpu cycles. Do you plan on generating every possible string at compile time ? I call that code bloat.
I dont think there is an acceptable solution to make everyone happy. Printf is easier to use for i8n but I like iostreams interface better. You can always write manipulators to do what you need for formatting with iostreams if needed. Best Regards, Richard V. Day