In Ruby why do we wirte code as require 'enumerator', instead of
require 'Enumerator' with uppercase? What happens if 'enumerator' is not
saved in the default path that Ruby usually looks for?
Posted via http://www.ruby-forum.com/.
Re: about require
On Sat, 2006-10-21 at 01:06 +0900, Li Chen wrote:=20
> Hi folks,
> In Ruby why do we wirte code as require 'enumerator', instead of=20
> require 'Enumerator' with uppercase?=20
Because classes and files don't have a 1:1 mapping, and filesystems on
some systems have case issues.
> What happens if 'enumerator' is not=20
> saved in the default path that Ruby usually looks for?
Then it won't work unless you alter the path or put it in the right
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
-----END PGP SIGNATURE-----
|All times are GMT. The time now is 07:16 AM.|
Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.