rubygems/rubygems — pull request #396 by grosser (2012-11-11 18:53:15+00:00)
Title: 5x speed anyone ?

startup speed for `time ruby -r active_record/version -e ''`
and would equally affect any other simple ruby program that needs to load only a few other gems,
and should be neutral to bigger apps.

before:
```
real	0m0.808s
user	0m0.375s
sys	0m0.067s
```

after:
```
real	0m0.167s
user	0m0.132s
sys	0m0.033s
```

It's definitely not perfect, e.g. 1.2.3-rc2 would not be supported, but e.g. tweaking the filenames of stored gems to replace - in versions with -- and maybe adding the platform could solve those edge-cases.
Also making the spec itself aware of being a stub and replacing itself when more info is needed could make it less disrupting for other users of specifications. But for now just a small idea to see if you like it / want to hack on it :)