Re: Win64 warnings about size_t
От | Magnus Hagander |
---|---|
Тема | Re: Win64 warnings about size_t |
Дата | |
Msg-id | 9837222c1001011128p6b567979g1c213dee4ac33e4@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Win64 warnings about size_t (Peter Eisentraut <peter_e@gmx.net>) |
Ответы |
Re: Win64 warnings about size_t
|
Список | pgsql-hackers |
On Fri, Jan 1, 2010 at 20:12, Peter Eisentraut <peter_e@gmx.net> wrote: > On fre, 2010-01-01 at 20:01 +0100, Magnus Hagander wrote: >> .\src\backend\utils\mmgr\aset.c(701): warning C4334: '<<' : result >> of 32-bit shift implicitly converted to 64 bits (was 64-bit shift >> intended?) >> .\src\backend\utils\mmgr\aset.c(705): warning C4334: '<<' : result >> of 32-bit shift implicitly converted to 64 bits (was 64-bit shift >> intended?) >> >> Perhaps we need some casting there? > > This shouldn't be a problem for the same reason that casting size_t to > int is not a problem in the PostgreSQL backend code, but perhaps writing > 1L << ... would fix it. 1L didn't fix it. 1LL did, however. ISTM that this is a warning we don't want to disable, so assuming that should be safe on other platforms (it passes on my 32-bit linux without warnings or anything), I'd vote for putting it in there. -- Magnus HaganderMe: http://www.hagander.net/Work: http://www.redpill-linpro.com/
В списке pgsql-hackers по дате отправления: