Add PrintTo for dynamic
[folly.git] / folly / json.h
index ead3afd01bec45a6618fdb6da217bb06d1269a4d..3d229f3f1f61d01eff6a950a2d30c34c81f986c0 100644 (file)
@@ -41,6 +41,8 @@
 #ifndef FOLLY_JSON_H_
 #define FOLLY_JSON_H_
 
+#include <iosfwd>
+
 #include <folly/dynamic.h>
 #include <folly/FBString.h>
 #include <folly/Range.h>
@@ -158,6 +160,11 @@ fbstring toJson(dynamic const&);
  */
 fbstring toPrettyJson(dynamic const&);
 
+/*
+ * Printer for GTest.
+ * Uppercase name to fill GTest's API, which calls this method through ADL.
+ */
+void PrintTo(const dynamic&, std::ostream*);
 //////////////////////////////////////////////////////////////////////
 
 }