Skip to content

Instantly share code, notes, and snippets.

@JeroenKnoops
Created January 15, 2013 21:22
Show Gist options
  • Save JeroenKnoops/4542188 to your computer and use it in GitHub Desktop.
Save JeroenKnoops/4542188 to your computer and use it in GitHub Desktop.
Difference between RubyParser 2.3.1 and RubyParser 3.1.1
RubyParser.new.parse ('"#{_("test3")}"')
=> s(:dstr, "", s(:evstr, s(:call, nil, :_, s(:arglist, s(:str, "test3"))))) # 2.3.1
=> s(:dstr, "", s(:evstr, s(:call, nil, :_, s(:str, "test3")))) # 3.1.1
RubyParser.new.parse ('_("test")')
=> s(:call, nil, :_, s(:arglist, s(:str, "test"))) # 2.3.1
=> s(:call, nil, :_, s(:str, "test")) # 3.1.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment