aboutsummaryrefslogtreecommitdiff
path: root/xsd
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2009-12-01 11:52:55 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2009-12-01 11:52:55 +0200
commit55ef06dd6198181dfb5b681d4fa366851c9c0fd1 (patch)
treea9342dc8c8b93d232707153ae07b04a437df7379 /xsd
parentec71f35c671255d1649a3c92f3f089ba0bd00020 (diff)
Map empty schema enumerations to the 'empty' C++ enumerator name
Diffstat (limited to 'xsd')
-rw-r--r--xsd/cxx/tree/name-processor.cxx4
1 files changed, 4 insertions, 0 deletions
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");