From: Michael Orlitzky Date: Mon, 4 Mar 2019 02:26:31 +0000 (-0500) Subject: src/IPv4Address.hs: fix the inverse toEnum/fromEnum property on x86. X-Git-Tag: 0.5.1~13 X-Git-Url: http://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=ac5698aeedccb731b4d9494b19efaf62dc70791a;hp=ac5698aeedccb731b4d9494b19efaf62dc70791a;p=hath.git src/IPv4Address.hs: fix the inverse toEnum/fromEnum property on x86. The second half of the fix in the previous commit turned out to be in the test itself. The "smallness test" that I was using was to compare against the number (2^32 - 1), which works great if said number is interpreted as a 64-bit integer. However on x86 systems, it's a 32-bit integer, namely negative one! Oops. This commit splits that test into two; one that tests randomly-generated Int32s, and one that tests randomly-generated Int64s. Hopefully this ensures that no similar problems with the machine Int type creep in. ---