From: Rusty Russell Date: Wed, 3 Nov 2010 00:11:07 +0000 (+1030) Subject: jmap: fix aliasing issues, one real testcase bug X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=09fde153ba7a68715dcad3b53cbbb8804c3d2356;hp=09fde153ba7a68715dcad3b53cbbb8804c3d2356 jmap: fix aliasing issues, one real testcase bug Compiling with gcc -O3 added some more warnings, especially about aliasing. By setting Word_t to size_t we fix some of them, but jmap_@name_firstval in JMAP_DEFINE_PTRIDX_TYPE we need to use a real size_t rather than lazily casting our index to a size_t *. Gcc also spotted taht we used idx[NUM] in test/run-ptridx-type.c; allocate that and make the usage explicit. ---