lua-users home
lua-l archive

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


Yes.

The fact that patches exist (powerpatch or risclua, ...) shows that
bitlib isn't a de facto standard, maybe only for those using simple
expressions, or not motivated to rely on a patch or to create a user
data.
Speed is a concern to me. And LuaJIT may not be the solution depending
on the target architectures. function inlining is not here yet, and
probably not so easy when one use local bor = bitlib.bor anywhere.
I really don't like the idea to go to function. Operators are not
function.
I'd much prefer |, &, ^, <<, >> to be operators with extensible
semantic. Would people using +, *, -, /, % be happy to use function
instead? 

PS: could lua 6 or whatever add something like operator op priority "p"
(...) ... end;  op2 = op;  v = a $op b $op2 c ; and then really be
extensible? Well this wouldn't allow the space operator that was once
discusses by stroustrup... but I'm only challenging)

-----Original Message-----
From: lua-bounces@bazar2.conectiva.com.br
[mailto:lua-bounces@bazar2.conectiva.com.br] On Behalf Of Klaus Ripke
Sent: Friday, September 22, 2006 11:10 AM
To: Lua list
Subject: Re: boolean operators

On Fri, Sep 22, 2006 at 08:53:52AM +0100, Paul Hudson wrote:
> Correct. Functions would be fine, but it would help us if the library
was
> built in or otherwise deemed an "official" extension (so that it would
> continue to be updated as Lua evolves, and the APIs would be kept
similarly
> stable to Lua's core APIs).
... and probably it would help in order to make them candidates
for LuaJIT inlining.

Any objections to consider Reuben's bitlib the de facto standard?