From 51b119f0fc462feded000430a0acfb827ddf800f Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Fri, 1 Aug 2014 20:43:51 +1000 Subject: [PATCH] io: move identer ostream to util namespace --- io.hpp | 13 ++++++++----- io.ipp | 14 +++++++------- 2 files changed, 15 insertions(+), 12 deletions(-) diff --git a/io.hpp b/io.hpp index 11b6d657..ae08874e 100644 --- a/io.hpp +++ b/io.hpp @@ -87,10 +87,18 @@ namespace util { }; + //------------------------------------------------------------------------- template indented make_indented (const T &_data); + + //------------------------------------------------------------------------- + template + std::ostream& + operator<< (std::ostream &os, const util::indented &v); + + //------------------------------------------------------------------------- class scoped_cwd { public: @@ -147,11 +155,6 @@ namespace util { }; } - -template -std::ostream& -operator<< (std::ostream &os, const util::indented &v); - #include "io.ipp" #endif diff --git a/io.ipp b/io.ipp index e053eeb8..e13f5d3c 100644 --- a/io.ipp +++ b/io.ipp @@ -17,13 +17,13 @@ namespace util { make_indented (const T &_data) { return indented (_data); } -} -template -std::ostream& -operator<< (std::ostream &os, const util::indented &&v) { - util::indenter raii (os); - os << v.data; - return os; + template + std::ostream& + operator<< (std::ostream &os, const util::indented &&v) { + util::indenter raii (os); + os << v.data; + return os; + } }