Issue 205: Make iostream support optional.

This commit is contained in:
Richard Maxwell
2015-10-16 08:04:53 +13:00
parent 221eeda912
commit 2cca51c744
3 changed files with 15 additions and 1 deletions
+2
View File
@@ -1252,11 +1252,13 @@ FMT_FUNC void fmt::print(CStringRef format_str, ArgList args) {
print(stdout, format_str, args);
}
#ifndef FMT_NO_STREAM_LIBRARIES
FMT_FUNC void fmt::print(std::ostream &os, CStringRef format_str, ArgList args) {
MemoryWriter w;
w.write(format_str, args);
os.write(w.data(), w.size());
}
#endif
FMT_FUNC void fmt::print_colored(Color c, CStringRef format, ArgList args) {
char escape[] = "\x1b[30m";