From: Austin Ziegler Date: 2005-12-02T23:27:02+09:00 Subject: Re: Is there any relevant difference between require and require_gem? On 12/2/05, Lars Olsson wrote: > When using Rubygems, is there any *relevant* difference between using > require and require_gem (aside from the versioning possibilities)? > According to the docs require searches the standard library first. Is > this true for require_gem too, or does that method only search the gem > repository? Is is faster? > > Example: > require 'rubygems' > > # Is any of the two methods below "better" in any way? > require 'sqlite3' > > # Or > > require_gem 'sqlite3-ruby' Yes. require_gem, at least for some gems, and *definitely* for future versions of PDF::Writer and other packages that I write will only require the gem. It will not autorequire the core functionality as it does now. -austin -- Austin Ziegler * halostatue@gmail.com * Alternate: austin@halostatue.ca