Too Slow...
Having been forcefully reminded how sucky C++'s output formatting operators are to use, I started planning to write something better.
My preliminary design had one able to write something like this:
My preliminary design had one able to write something like this:
Fmt hexb("%02X");
cout << hexb % 0x12 << endl;
That seemed logical enough. While I was looking into what I would need to do to write it, I discovered it already exists. Its the format boost library. They even use operator% in the same way. The only major differences are:- Mine is in the design stage. Theirs exists.
- They have a whole lot more options than I had thought of.
- They called it format, while I called my Fmt.