lua-users home
lua-l archive

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


> On Mon, Oct 25, 2010 at 1:49 PM, Roberto Ierusalimschy
> <roberto@inf.puc-rio.br> wrote:
> >> 5.1.4
> >> lgc.c(288) : warning C4334: '<<' : result of 32-bit shift implicitly
> >> converted to 64 bits (was 64-bit shift intended?)
> >> ltable.c(323) : warning C4334: '<<' : result of 32-bit shift
> >> implicitly converted to 64 bits (was 64-bit shift intended?)
> >> ltable.c(376) : warning C4334: '<<' : result of 32-bit shift
> >> implicitly converted to 64 bits (was 64-bit shift intended?)
> >
> > Do you know what that means? This is (1 << (x)), where x is an unsigned
> > byte. How shoud I write that to avoid this implicit conversion?
> 
> 1L << x or maybe 1LL << x?

I do not intend a 64-bit shift. I intend a 32-bit shift (plus a way to
stop the compiler trying to guess what I intend).

-- Roberto