From 3433e10ec1617e55b137c8447a2be9c70130a196 Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Thu, 26 Apr 2012 18:20:08 +1000 Subject: [PATCH] Move the json output operator into json namespace --- json.cpp.rl | 2 +- json.hpp | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/json.cpp.rl b/json.cpp.rl index 8d311ebc..ab53c8c5 100644 --- a/json.cpp.rl +++ b/json.cpp.rl @@ -560,5 +560,5 @@ json::null::write (std::ostream &os) const { } ostream& -operator <<(ostream &os, const json::node &n) +json::operator <<(ostream &os, const json::node &n) { return n.write (os); } diff --git a/json.hpp b/json.hpp index 4714b1ce..0ac699e8 100644 --- a/json.hpp +++ b/json.hpp @@ -276,11 +276,10 @@ namespace json { template T&& from_json (const json::node&); + + std::ostream& + operator <<(std::ostream &os, const json::node &n); } - -std::ostream& -operator <<(std::ostream &os, const json::node &n); - #endif