Categories: None [Edit]
ruby_parser
ruby_parser (RP) is a ruby parser written in pure ruby (utilizing
racc--which does by default use a C extension). It outputs
s-expressions which can be manipulated and converted back to ruby via
the ruby2ruby gem.
As an example:
def conditional1 arg1
return 1 if arg1 == 0
return 0
end
becomes:
s(:defn, :conditional1, s(:args, :arg1),
s(:if,
s(:call, s(:lvar, :arg1), :==, s(:lit, 0)),
s(:return, s(:lit, 1)),
nil),
s(:return, s(:lit, 0)))
Tested against 801,039 files from the latest of all rubygems (as of 2013-05):
* 1.8 parser is at 99.9739% accuracy, 3.651 sigma
* 1.9 parser is at 99.9940% accuracy, 4.013 sigma
* 2.0 parser is at 99.9939% accuracy, 4.008 sigma
* 2.6 parser is at 99.9972% accuracy, 4.191 sigma
* 3.0 parser has a 100% parse rate.
* Tested against 2,672,412 unique ruby files across 167k gems.
* As do all the others now, basically.
Total
Ranking: 269 of 172,883
Downloads: 78,482,825
Daily
Ranking: 293 of 172,875
Downloads: 78,253
Downloads Trends
Ranking Trends
Num of Versions Trends
Popular Versions (Major)
Popular Versions (Major.Minor)
Depended by
Rank | Downloads | Name |
---|---|---|
887 | 24,231,330 | html2haml |
1,063 | 17,929,296 | flay |
1,146 | 15,765,827 | gettext_i18n_rails |
1,233 | 13,789,335 | flog |
1,308 | 12,521,172 | ruby2ruby |
1,722 | 6,919,012 | rubycritic |
2,251 | 3,962,259 | fasterer |
2,649 | 2,733,441 | hairtrigger |
2,801 | 2,428,400 | protocol |
3,011 | 2,021,419 | roodi |
3,116 | 1,909,751 | churn |
4,507 | 805,533 | safemode |
4,821 | 690,812 | i18nliner |
4,965 | 646,133 | sourcify |
5,405 | 538,514 | debride |
5,432 | 532,348 | dawnscanner |
6,241 | 388,379 | quality |
6,267 | 383,627 | wrong |
6,592 | 344,008 | ripper_ruby_parser |
7,097 | 290,929 | partialruby |
Depends on
Rank | Downloads | Name |
---|---|---|
11 | 618,760,160 | rake |
163 | 127,265,998 | racc |
171 | 120,976,302 | rdoc |
244 | 83,710,651 | sexp_processor |
1,626 | 7,677,405 | hoe |
22,737 | 42,668 | oedipus_lex |
Owners
# | Gravatar | Handle |
---|---|---|
1 | zenspider |