Derive Show, Eq, Ord, Read for Control.Applicative.ZipList; fixes #5787

Patch from merijn.
Add atomicReadMVar to Control.Concurrent.MVar and friends.

Also renumber thread statuses as necessary.

Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
Implement tryAtomicReadMVar.

Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
Fix build.

We forgot to import tryAtomicReadMVar.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
Rename atomicReadMVar and friends to readMVar, replacing old readMVar.

Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
Minor rewording.

Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
Expose new Word operation to swap endianness for Word{16,32,64}

Authored-by: Vincent Hanquez <tab@snarc.org>
Signed-off-by: Austin Seipp <aseipp@pobox.com>
Fix #7787

Now the pair is evaluated strictly inside the exception handler.  I
figured this would be less likely to introduce space leaky bugs than
using an irrefutable pattern match.
Add test for #7787
Fix GHC.Enum on 32bit platforms; fixes #8072

Diagnosed by int-e.

MachDeps.h wasn't being included in Enum.lhs, and the old
WORD_SIZE_IN_BITS test didn't fail when WORD_SIZE_IN_BITS isn't
defined. Now we get an error instead.