Re: [ANN] Lua 5.2.0 (work1) now available
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: [ANN] Lua 5.2.0 (work1) now available
- From: Leo Razoumov <slonik.az@...>
- Date: 2010年1月14日 16:38:48 -0500
On 2010年01月14日, David Burgess <dabsoft@gmail.com> wrote:
> I happen to agree with all that Mike has presented.
> especially:
>
> > There is no cost to have two explicitly named functions and it
> > makes the intent immediately obvious:
> >
> > bit.lshift(x, 8) vs. bit.rshift(x, 8)
> >
> > Readibility is important.
>
As someone who did bit-operations for living (chip design) I can
attest that having distinct names for left and right shifts *is*
important. C-language got it exactly right with its << and >>
operators. In Lua lshift and rshift would do just fine.
--Leo--