lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Ryanne Thomas Dolan wrote:

In the 5.1 manual's description of package.loaded, it says
require will return the value of package.loaded
[modulename] if the value "is not false".  I believe this
should read "is not false or nil".

The full quote is:

When you require a module modname and
package.loaded[modname] is not false, require simply
returns the value stored there.

I can see how someone might misread this but, consistently
with the rest of the manual, "false" here is in a regular
typeface, which means it's being used as an adjective (e.g.,
"*nil* is a false value"; the keyword "false" always appears
in a special typeface (e.g., "the boolean value *false*".

Sorry this isn't threaded -- for some reason most messages
don't make it to my Hotmail account and I have to read them
in the archive and reply to them by starting a new thread.