[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Wishlists and Modules (was [ANN] libmc)
 
- From: Roberto Ierusalimschy <roberto@...>
 
- Date: Thu, 3 Sep 2009 13:02:46 -0300
 
> Loaders of the standard libraries are designed to be just executed.
> Modules that are designed to be loaded through require may rely on the
> extra features of require to work properly (ie. setting
> package.loaded[modname] to the return value of the loader).
The standard libraries do that too:
> print(io)                 --> table: 0x806ce40
> print(package.loaded.io)  --> table: 0x806ce40
> print(require("io"))      --> table: 0x806ce40
-- Roberto