From 4d3692a500bd5cf2bd500e1eb0632850ca8260ab Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 2 Jun 2011 04:27:02 +0200 Subject: Do not store flags in containers --- libxsd/xsd/cxx/tree/parsing.txx | 34 +++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) (limited to 'libxsd/xsd/cxx/tree/parsing.txx') diff --git a/libxsd/xsd/cxx/tree/parsing.txx b/libxsd/xsd/cxx/tree/parsing.txx index 929bf9f..bdeb539 100644 --- a/libxsd/xsd/cxx/tree/parsing.txx +++ b/libxsd/xsd/cxx/tree/parsing.txx @@ -176,17 +176,19 @@ namespace xsd template list:: list (const xercesc::DOMElement& e, flags f, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + : sequence (c) { - init (text_content (e), &e); + init (text_content (e), &e, f & ~flags::keep_dom); } template list:: list (const xercesc::DOMAttr& a, flags f, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + : sequence (c) { - init (xml::transcode (a.getValue ()), a.getOwnerElement ()); + init (xml::transcode (a.getValue ()), + a.getOwnerElement (), + f & ~flags::keep_dom); } template @@ -195,14 +197,16 @@ namespace xsd const xercesc::DOMElement* e, flags f, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + : sequence (c) { - init (s, e); + init (s, e, f & ~flags::keep_dom); } template void list:: - init (const std::basic_string& s, const xercesc::DOMElement* parent) + init (const std::basic_string& s, + const xercesc::DOMElement* parent, + flags f) { if (s.size () == 0) return; @@ -226,7 +230,7 @@ namespace xsd ptr r ( new T (basic_string (data + i, j - i), parent, - this->flags_, + f, this->container_)); this->v_.push_back (r); @@ -240,7 +244,7 @@ namespace xsd ptr r ( new T (basic_string (data + i, size - i), parent, - this->flags_, + f, this->container_)); this->v_.push_back (r); @@ -252,16 +256,16 @@ namespace xsd template list:: - list (const xercesc::DOMElement& e, flags f, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + list (const xercesc::DOMElement& e, flags, container* c) + : sequence (c) { init (text_content (e), &e); } template inline list:: - list (const xercesc::DOMAttr& a, flags f, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + list (const xercesc::DOMAttr& a, flags, container* c) + : sequence (c) { init (xml::transcode (a.getValue ()), a.getOwnerElement ()); } @@ -270,9 +274,9 @@ namespace xsd inline list:: list (const std::basic_string& s, const xercesc::DOMElement* parent, - flags f, + flags, container* c) - : sequence (flags (f & ~flags::keep_dom), c) // ambiguous + : sequence (c) { init (s, parent); } -- cgit v1.1