lua-users home
lua-l archive

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


David Burgess wrote:
> >(101) GetModuleFileName -> GetModuleFileNameA
> >(115) FormatMessage -> FormatMessageA
> >(128) LoadLibrary -> LoadLibraryA
> >
> These three functions have previously undegone vigorous discussion.
> (I am too lazy to loojup and refernce the msg thread).
> I believe that the verdict was to leave them as they are.

Well, here's a recap of the discussion threads:

I've proposed it, you've been in favour, Wim Couwenberg said that
these might not be the "official" API entries.

The subject reappeared a few months later, Roberto offered a
patch to luaconf.h. I argued that it doesn't work and did some
research to find out that the *A symbols are present in every
Windows version I could get hold of. Then you've proposed doing
conversion to/from UTF-8 and using the *W calls (which is IMHO
overdoing it a bit).

After that, the discussion died down and nothing happened. Alas,
the problem didn't disappear:

I've done some further research and e.g. APR, Firefox, PHP,
Info-ZIP, Boost and quite a few other open source products
happily use the *A calls (e.g. look for CreateFileA at Google
Codesearch). I mean ... even M$ mentions the *A and the *W
variants in their MSDN docs for every API entry.

IMHO it makes sense to apply the above mentioned changes in
loadlib.c. Unconditionally that is, because the *W variants
cannot ever work, given the surrounding code.