Questions tagged [fastformat]
6 questions
16
votes
6 answers
Is there a 'catch' with FastFormat?
I just read about the FastFormat C++ i/o formatting library, and it seems too good to be true: Faster even than printf, typesafe, and with what I consider a pleasing interface:
// prints: "This formats the remaining arguments based on their order -…

Roddy
- 66,617
- 42
- 165
- 277
4
votes
2 answers
Safe/flexible facade for Windows FormatMessage
I need to use FormatMessage() for a project, but I don't like its scary interface. Does anyone know of a facade that tidies it up while still allowing for the replacement parameters?
I just read the second part of the FastFormat introduction, and am…

dcw
- 3,481
- 2
- 22
- 30
4
votes
1 answer
How can I guarantee type safety in a function that accepts an unlimited amount of arguments?
The FastFormat library works like this:
string example;
fastformat::fmt(example, "I am asking {0} question on {1}", 1, "stackoverflow");
It also claims "100% type-safety". I can understand how other libraries such as boost::format achieve that by…

frm
- 153
- 1
- 6
2
votes
2 answers
Do C++ formatting libraries generally fall back to *sprintf for numeric formatting?
I am wondering whether "all" C++ formatting libraries eventually fall back to a *sprintf function to format numbers.
I am asking this because:
Looking at the iostreams library that comes with Visual C++, I can see that numbers input into a stream…

Martin Ba
- 37,187
- 33
- 183
- 337
1
vote
0 answers
How do I format a number with commas using FastFormat?
How do I format a number with commas for thousand separators using FastFormat library?
For example,
7800 -> 7,800
5100100 -> 5,100,100

User
- 62,498
- 72
- 186
- 247
1
vote
1 answer
FastFormat on OS X
After reading a little about FastFormat, I decided to download and install it on my Macbook Pro, running OS X 10.8. I successfully got FastFormat to build, and ran the performance tests. Then I wrote a small test to check whether it works:
#include…

void-pointer
- 14,247
- 11
- 43
- 61