Fix a bug with io.write_int/[34] on MinGW64.

The implementations of io.write_int/[34] were casting their integer argument to
a long before printing it out.  This is incorrect on LLP64 platforms, since on
those platforms longs are 32-bit values (i.e. we were truncating 64-bit
integers to 32-bit integers when printing them out!).
Among other things, this was causing --smart-indexing to break on MinGw64,
since the bit vectors we generate for semidet atomic lookup switches were being
incorrectly printed in the generated C files.

library/io.m:
    Do not assume that sizeof(MR_Integer) <= sizeof(long) in the
    implementations of io.write_int.  For 64-bit Windows, this
    is not true.