4.6. CTypesISO

This module is part of the language-dependent part of the Foreign Function Interface (FFI) - for the language-independent part, see Section 4.9. It defines Haskell types corresponding the most important ISO types of C that are not covered in the module CTypes.

Every type has a constructor of the same name, which is currently exported, too. Given the large set of instances for each type, it is not clear if access to the concrete representation is really necessary. Some experience is needed before a final decision can be made in this respect.

4.6.1. Integral types

The following integral types have instaces for the classes Eq, Ord, Num, Read, Show, Enum, Typeable, Storable, Bounded, Real, Integral, and Bits:

newtype CPtrdiff	-- ptrdiff_t
newtype CSize		-- size_t
newtype CWChar		-- wchar_t
newtype CSigAtomic	-- sig_atomic_t

4.6.2. Numeric types

The following numeric types have instances for the classes Eq, Ord, Num, Read, Show, Enum, Typeable, and Storable:

newtype CClock		-- clock_t
newtype CTime		-- time_t

4.6.3. Misc types

The following types have instances for the classes: ???

newtype CFile		-- FILE
newtype CFpos		-- fpos_t
newtype CJmpBuf		-- jmp_buf