jasonroelofs/rbgccxml

Unable to use pregenerated XML

Closed this issue · 2 comments

config.delete[:pregenerated]

… should (at least) be

config.delete(:pregenerated)

Source: https://github.com/jameskilton/rbgccxml/blob/b8fb1f8427273c9a114029986b7b7920359f1c69/lib/rbgccxml/parser.rb#L11

As a workaround, instead of using RbGCCXML.parse, I did this funny little thing:

my_hash = { pregenerated: path_to_pregenerated_xml }
class << my_hash
  alias :delete :to_hash
end

rbgccxml_parsed_xml = RbGCCXML.parse([], my_hash

It’s a solution for now.

See #9 for further discussion. This in particular is fixed.