[xsd-users] Please don't use 'override' as a variable name

Eric Springer erikina at gmail.com
Mon Aug 22 20:43:38 EDT 2011


Hi,

One issue I'm have with XSD is the use of "override" in a couple places,

( e.g. in xsd 3.3.0, override an argument name to the function
"register_type" on line 229 of file:
cxx/tree/type-factory-map.txx)

Visual Studio treats 'override' as a keyword meaning that you are
overriding a virtual function, and
if you're not (e.g. you made a mistake, or the base signature changed)
it will fail to compile.

For other compilers we have a simple macro like "#define override " to
strip out override for compatibility

As a result, this means that when using xsd we need to patch the
system header manually, which is pretty
unideal and messy. It'd be really great if you guys could rename the variable
to something else :)

Thanks,
Eric Springer



More information about the xsd-users mailing list