lua-users home
lua-l archive

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

2010/10/22 Michal Kolodziejczyk <>:
> I think it would be resolvable in the future with current LR with change
> in module naming:
> local posix=require 'org.example.luaposix'
> or
> local posix=require 'org.example2.lposix'

Namespaces are definitely the way forward, but people don't like change ;)

The current LuaRocks situation is interesting: in my Lua C module dir I have:


Where is luaposix.  So you can specify what you want in
require(), but there are two problems:
(a) the above renaming scheme is order-dependent - happened because
lposix was there before luaposix
(b) it is overspecific.

It would be useful if this worked a bit more consistently and more
generically, i.e. the event of a module name clash one would end up
with package1-mod and package2-mod as the require names, as well as
mod (if you want to take a chance)

Note the lposix version number ;)

steve d.