-
chak@cse.unsw.edu.au. authored
Revision of Marcin's QError module * I think, there was a rough consensus that Marcin's module provides the right kind of interface for handling "errno"s * Malcolm preferred an enumeration, but Marcin made a convincing argument that this doesn't go well with architecture-dependent variations of "errno" * Recoded the hsc magic into autoconf magic * In hsc files, errno constants can be accessed directly; to provide access for ordinary Haskell programmer, constants for a range of common symbols are provided (their values are determined by configure) * Introduced an `Errno' newtype to increase type safety * renamed the throwIfXXX functions to throwErrnoIfXXX to have the original names available in the language independent MarshalError * FIXME: We need a thread local getErrno in the RTS! (It all compiles, but is still to be tested.)
d82e38d0