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: 335 of 188,252
Downloads: 132,038,842
Daily
Ranking: 593 of 188,232
Downloads: 42,214
Downloads Trends
Ranking Trends
Num of Versions Trends
Popular Versions (Major)
Popular Versions (Major.Minor)
Depended by
| Rank | Downloads | Name |
|---|---|---|
| 1,274 | 33,592,635 | html2haml |
| 1,354 | 30,170,957 | flay |
| 1,509 | 24,723,475 | flog |
| 1,700 | 18,634,121 | ruby2ruby |
| 1,902 | 14,821,525 | protocol |
| 1,919 | 14,604,364 | rubycritic |
| 2,309 | 9,089,259 | fasterer |
| 2,640 | 6,820,873 | hairtrigger |
| 3,852 | 2,723,711 | churn |
| 4,068 | 2,363,347 | roodi |
| 5,145 | 1,322,030 | debride |
| 5,999 | 900,271 | safemode |
| 6,106 | 863,017 | dawnscanner |
| 6,115 | 860,834 | i18nliner |
| 6,124 | 857,618 | sourcify |
| 7,224 | 584,117 | wrong |
| 7,365 | 565,821 | partialruby |
| 7,892 | 496,448 | quality |
| 8,490 | 420,110 | ripper_ruby_parser |
| 9,083 | 362,061 | brakeman-min |
Depends on
| Rank | Downloads | Name |
|---|---|---|
| 10 | 1,188,890,086 | rake |
| 60 | 602,062,281 | racc |
| 179 | 258,159,855 | rdoc |
| 323 | 140,699,274 | sexp_processor |
| 2,310 | 9,049,897 | hoe |
| 21,068 | 73,864 | oedipus_lex |
Owners
| # | Gravatar | Handle |
|---|---|---|
| 1 | zenspider |