diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2009-12-01 11:52:55 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2009-12-01 11:52:55 +0200 |
commit | 55ef06dd6198181dfb5b681d4fa366851c9c0fd1 (patch) | |
tree | a9342dc8c8b93d232707153ae07b04a437df7379 | |
parent | ec71f35c671255d1649a3c92f3f089ba0bd00020 (diff) |
Map empty schema enumerations to the 'empty' C++ enumerator name
-rw-r--r-- | NEWS | 3 | ||||
-rw-r--r-- | xsd/cxx/tree/name-processor.cxx | 4 |
2 files changed, 7 insertions, 0 deletions
@@ -48,6 +48,9 @@ Version 3.3.0 can process parts of the document as they become available as well as handle documents that are too large to fit into memory. + * Empty XML Schema enumeration values are now mapped to the 'empty' C++ + enumerator name instead of 'cxx'. + Version 3.2.0 * New option, --disable-warning, disables printing of a warning with diff --git a/xsd/cxx/tree/name-processor.cxx b/xsd/cxx/tree/name-processor.cxx index 456095f..1adfc38 100644 --- a/xsd/cxx/tree/name-processor.cxx +++ b/xsd/cxx/tree/name-processor.cxx @@ -249,6 +249,10 @@ namespace CXX // Enumerator name regex. // { + // By default map an empty enumerator to the 'empty' word. + // + enumerator_regex.push_back ("/^$/empty/"); + compile_regex (options.value<CLI::enumerator_regex> (), enumerator_regex, "enumerator"); |