There’s something I’m not getting about using 64-bit int keys with GHashTable; if anyone can correct me I’d be grateful. Here’s the basics of my code:

```
int main (void)
{
GHashTable *ht;
gpointer p;
gint64 key;
gint i, val, N = 4;
ht = g_hash_table_new(g_int64_hash, g_int64_equal);
for (i=0; i<N; i++) {
key = i + 1;
val = i + 10;
p = GINT_TO_POINTER(val);
g_hash_table_insert(ht, &key, p);
printf("%d: insert: key %ld, value %d (%p)\n", i, key, val, p);
}
for (i=0; i<N; i++) {
key = i + 1;
p = g_hash_table_lookup(ht, &key);
val = GPOINTER_TO_INT(p);
printf("%d: lookup: key %ld, value %d (%p)\n", i, key, val, p);
}
g_hash_table_destroy(ht);
return 0;
}
```

What I’m getting by way of output is

```
0: insert: key 1, value 10 (0xa)
1: insert: key 2, value 11 (0xb)
2: insert: key 3, value 12 (0xc)
3: insert: key 4, value 13 (0xd)
0: lookup: key 1, value 11 (0xb) // hmmm
1: lookup: key 2, value 11 (0xb)
2: lookup: key 3, value 12 (0xc)
3: lookup: key 4, value 13 (0xd)
```