[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua 5.2 beta: default module path incompatibility
- From: liam mail <liam.list@...>
- Date: Tue, 20 Sep 2011 12:26:23 +0100
On 20 September 2011 12:04, Dirk Laurie <dpl@sun.ac.za> wrote:
> It just took me 30 minutes of debugging time to realize that the reason
> my enhancements to mboxparser.lua worked under Lua 5.1.4 but not under
> Lua 5.2 was that the current version was not being used at all.
>
> Reason:
>
> The default set in luaconf.h for both package.path and package.cpath
> in Lua 5.2.0 beta puts the present working directory last, whereas in
> Lua 5.1.4 it was put first.
>
> The change seems not to be documented under either "Changes since Lua 5.1"
> or in the reference manual itself.
>
> It is difficult to understand why this change has been made. It causes
> any application distributed with customized versions of packages that
> happen to installed system-wide to break unless the application explicitly
> sets the path.
>
> Since the change is undocumented, I sincerely hope it is a bug.
>
> Dirk
>
>
I would think this is a bug otherwise some of the documentation [1][2]
could be seen as misleading if one _assumes_ the stated path is the
default.
[1] http://www.lua.org/work/doc/manual.html#pdf-package.searchers
[2] http://www.lua.org/work/doc/manual.html#pdf-package.searchpath