summaryrefslogtreecommitdiff
path: root/src/declare.cc
diff options
context:
space:
mode:
authorAdrian Thurston <thurston@colm.net>2018-05-06 19:15:19 -0400
committerAdrian Thurston <thurston@colm.net>2018-05-06 19:15:19 -0400
commitd6b4b6dc9985849cecb44a0e397f9bfbb8bc89b2 (patch)
treeeabd98909730343097cba412de88bdd64c964381 /src/declare.cc
parent776ddfc296be0edd2093b932e2b61c6407f29b94 (diff)
downloadcolm-d6b4b6dc9985849cecb44a0e397f9bfbb8bc89b2.tar.gz
added xml() and xmlac(), which which collect xml to strings
Going to eliminate the specialized print forms, instead opting for functions. Later on we can make these lazy.
Diffstat (limited to 'src/declare.cc')
-rw-r--r--src/declare.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/declare.cc b/src/declare.cc
index 10c56902..e7357e6e 100644
--- a/src/declare.cc
+++ b/src/declare.cc
@@ -1024,6 +1024,14 @@ void Compiler::declareGlobalFields()
method = initFunction( uniqueTypeInt, rootNamespace, globalObjectDef, "system",
IN_SYSTEM, IN_SYSTEM, uniqueTypeStr, true );
+ method = initFunction( uniqueTypeStr, rootNamespace, globalObjectDef, "xml",
+ IN_TREE_TO_STR_XML, IN_TREE_TO_STR_XML, uniqueTypeAny, true );
+ method->useCallObj = false;
+
+ method = initFunction( uniqueTypeStr, rootNamespace, globalObjectDef, "xmlac",
+ IN_TREE_TO_STR_XML_AC, IN_TREE_TO_STR_XML_AC, uniqueTypeAny, true );
+ method->useCallObj = false;
+
addStdin();
addStdout();
addStderr();