summaryrefslogtreecommitdiff
path: root/libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx')
-rw-r--r--libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx57
1 files changed, 27 insertions, 30 deletions
diff --git a/libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx b/libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx
index e25e742..19b9df2 100644
--- a/libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx
+++ b/libxsd-frontend/xsd-frontend/semantic-graph/any-attribute.cxx
@@ -1,8 +1,9 @@
// file : xsd-frontend/semantic-graph/any-attribute.cxx
-// 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
+#include <cutl/compiler/type-info.hxx>
+
#include <xsd-frontend/semantic-graph/any-attribute.hxx>
#include <xsd-frontend/semantic-graph/compositors.hxx>
@@ -10,30 +11,11 @@ namespace XSDFrontend
{
namespace SemanticGraph
{
- namespace RTTI = Cult::RTTI;
-
- using RTTI::Access;
- using RTTI::TypeInfo;
-
- namespace
- {
- struct AnyAttributeInit
- {
- AnyAttributeInit ()
- {
- TypeInfo ti (typeid (AnyAttribute));
- ti.add_base (Access::public_, true, typeid (Nameable));
- RTTI::insert (ti);
- }
-
- } any_attribute_init_;
- }
-
AnyAttribute::
AnyAttribute (Path const& file,
- UnsignedLong line,
- UnsignedLong column,
- WideString const& namespaces)
+ unsigned long line,
+ unsigned long column,
+ String const& namespaces)
: Node (file, line, column),
prototype_ (0)
{
@@ -41,11 +23,11 @@ namespace XSDFrontend
// chararcter.
//
- for (Size i (0), j (namespaces.find (L' '));;)
+ for (size_t i (0), j (namespaces.find (L' '));;)
{
- if (j != WideString::npos)
+ if (j != String::npos)
{
- namespaces_.push_back (WideString (namespaces, i, j - i));
+ namespaces_.push_back (String (namespaces, i, j - i));
i = j + 1;
j = namespaces.find (L' ', i);
@@ -54,7 +36,7 @@ namespace XSDFrontend
{
// Last element.
//
- namespaces_.push_back (WideString (namespaces, i));
+ namespaces_.push_back (String (namespaces, i));
break;
}
}
@@ -62,8 +44,8 @@ namespace XSDFrontend
AnyAttribute::
AnyAttribute (Path const& file,
- UnsignedLong line,
- UnsignedLong column,
+ unsigned long line,
+ unsigned long column,
NamespaceIterator begin,
NamespaceIterator end)
: Node (file, line, column),
@@ -110,5 +92,20 @@ namespace XSDFrontend
return namespace_ (scope ());
}
+
+ namespace
+ {
+ using compiler::type_info;
+
+ struct AnyAttributeInit
+ {
+ AnyAttributeInit ()
+ {
+ type_info ti (typeid (AnyAttribute));
+ ti.add_base (typeid (Nameable));
+ insert (ti);
+ }
+ } any_attribute_init_;
+ }
}
}