Hi Camillo,
On Tue, Mar 20, 2012 at 8:35 AM, Camillo Bruni camillo.bruni@inria.frwrote:
I am quickly trying to limit the number of warnings we get when compiling cog.
The current output is amazingly verbose, and utterly useless when looking for possible bugs :/. Furthermore it seems that cared about the following warning:
/Users/cami-data/education/phd/project/cog/dh83s-blessed/src/vm/gcc3x-cointerp.c:2066: warning: passing argument 1 of ‘longAt’ makes integer from pointer without a cast
what would be the easiest way to introduce an auto-cast for longAt and family? I think the easiest solution would be to reintroduce the macros that are currently disabled, no?
This doesn't seem right to me. I've attached the warnings I get when I compile Cog with gcc 4.2.1 (on Mac OS X). There are 39 lines for about 20 warnings. The unique warnings are
"bytecodeSetSelector" redefined assignment makes integer from pointer without a cast format '%ld' expects type 'long int', but argument 2 has type 'sqInt' ignoring asm-specifier for non-static local variable 'currentBytecode' ignoring asm-specifier for non-static local variable 'localIP' ignoring asm-specifier for non-static local variable 'localSP' initialization from incompatible pointer type left shift count >= width of type passing argument 1 of 'printHex' makes integer from pointer without a cast passing argument 2 of 'sqAllocateMemoryMac' makes pointer from integer without a cast return makes integer from pointer without a cast
So no warnings about longAt at all. I wonder what is different between your compile environment and mine. Are we both talking about Mac or are you on linux?
best cami