From 1009fdcd8d20cf938ecc24ead4d9c477686284e5 Mon Sep 17 00:00:00 2001 From: Orvid King Date: Wed, 29 Jul 2015 14:46:30 -0700 Subject: [PATCH 1/1] Handle MSVC in FBString.h Summary: Specifically, MSVC doesn't define `std::__ostream_insert`, so just write to the stream instead. Closes #270 Reviewed By: @yfeldblum Differential Revision: D2283960 Pulled By: @sgolemon --- folly/FBString.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/folly/FBString.h b/folly/FBString.h index 53ade9b7..4afce748 100644 --- a/folly/FBString.h +++ b/folly/FBString.h @@ -2370,6 +2370,9 @@ operator<<( os.setstate(std::ios_base::badbit | std::ios_base::failbit); } } +#elif defined(_MSC_VER) + // MSVC doesn't define __ostream_insert + os.write(str.data(), str.size()); #else std::__ostream_insert(os, str.data(), str.size()); #endif -- 2.34.1