Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

keep it parametery Seattle

  • Loading branch information...
commit a0fcb911ece01f9e4aad85272b530e9105b301ba 1 parent 1e4cae8
@tenderlove authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/zomg/idl/visitors/ruby_sexp.rb
View
7 lib/zomg/idl/visitors/ruby_sexp.rb
@@ -66,7 +66,7 @@ def visit_Operation(o)
o.name.to_sym,
[:scope,
[:block,
- [:args] + o.children.map { |c| c.accept(self).to_s.downcase.to_sym },
+ [:args] + o.children.map { |c| paramify(c.accept(self)) },
[:fcall, :raise, [:array,
[:call, [:const, :NotImplementedError], :new]]
]
@@ -162,6 +162,11 @@ def classify(string)
s = string.to_s
:"#{s.slice(0,1).upcase}#{s[1..-1]}"
end
+
+ def paramify(string)
+ s = string.to_s
+ :"#{s.slice(0,1).downcase}#{s[1..-1]}"
+ end
end
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.