aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/expr-to-xml.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2006-09-04 21:06:23 +0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2006-09-04 21:06:23 +0000
commit75068e7d753cf6cbe45a4bf294000dca9bd41d8b (patch)
treec6274cc10caab08349b5585206034f41ca4a575f /src/libexpr/expr-to-xml.cc
parentaab88127321344d5818d823bff515d127108d058 (diff)
* Use a proper namespace.
* Optimise header file usage a bit. * Compile the parser as C++.
Diffstat (limited to 'src/libexpr/expr-to-xml.cc')
-rw-r--r--src/libexpr/expr-to-xml.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/libexpr/expr-to-xml.cc b/src/libexpr/expr-to-xml.cc
index cd9112a42..b84c0058e 100644
--- a/src/libexpr/expr-to-xml.cc
+++ b/src/libexpr/expr-to-xml.cc
@@ -1,10 +1,12 @@
#include "expr-to-xml.hh"
-
#include "xml-writer.hh"
#include "nixexpr-ast.hh"
#include "aterm.hh"
+namespace nix {
+
+
static XMLAttrs singletonAttrs(const string & name, const string & value)
{
XMLAttrs attrs;
@@ -84,9 +86,12 @@ static void printTermAsXML(Expr e, XMLWriter & doc)
}
-void printTermAsXML(Expr e, ostream & out)
+void printTermAsXML(Expr e, std::ostream & out)
{
XMLWriter doc(true, out);
XMLOpenElement root(doc, "expr");
printTermAsXML(e, doc);
}
+
+
+}