summaryrefslogtreecommitdiff
path: root/xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 15:25:44 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 15:25:44 +0200
commit8286ac511144e4f17d34eac9affb97e50646344a (patch)
treef1af7320d7b6be6be059216d0ad08ac7b4f73fd0 /xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx
parenta15cf65c44d5c224169c32ef5495b68c758134b7 (diff)
Imported Upstream version 4.0.0upstream/4.0.0
Diffstat (limited to 'xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx')
-rw-r--r--xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx b/xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx
index a7ab357..9a8f976 100644
--- a/xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx
+++ b/xsd/libxsd/xsd/cxx/tree/std-ostream-operators.hxx
@@ -1,6 +1,5 @@
// file : xsd/cxx/tree/std-ostream-operators.hxx
-// author : Boris Kolpackov <boris@codesynthesis.com>
-// copyright : Copyright (c) 2005-2010 Code Synthesis Tools CC
+// copyright : Copyright (c) 2005-2014 Code Synthesis Tools CC
// license : GNU GPL v2 + exceptions; see accompanying LICENSE file
#ifndef XSD_CXX_TREE_STD_OSTREAM_OPERATORS_HXX
@@ -25,6 +24,7 @@ namespace xsd
inline std::basic_ostream<C>&
operator<< (std::basic_ostream<C>& os, const type&)
{
+ // Not printing DOM content even if it's there.
return os;
}
@@ -33,8 +33,11 @@ namespace xsd
//
template <typename C, typename B>
inline std::basic_ostream<C>&
- operator<< (std::basic_ostream<C>& os, const simple_type<B>&)
+ operator<< (std::basic_ostream<C>& os, const simple_type<C, B>& x)
{
+ if (!x.null_content ())
+ os << x.text_content ();
+
return os;
}