You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's been a while but grepping through the code, we seem to invoking "camelize" on attribute, element, simple type, and complex type names and setting that to the ClassBuilder.klass_name, which gets passed onto Object.const_set
String#camelize defined in active support will convert "foo-bar" into "Foo-bar" which is an invalid const name, hence the issue.
Perhaps swapping dashes (-) with underscores (_) before invoking camlize is invoked may work. Don't currently have time for this, but pr's / other thoughts are more than welcome.
If I have an XML element with a dash (-) within its name (e.g. buffer-cache),
schema.to :ruby_classes
fails with the following error:ruby-1.9.3-p551/gems/rxsd-0.5.2/lib/rxsd/builders/ruby_class.rb:39:in
const_set': wrong constant name Buffer-cache (NameError)`Does anyone have any thoughts regarding this issue?
The text was updated successfully, but these errors were encountered: