haskell-gi-0.15: Generate Haskell bindings for GObject Introspection capable libraries

Safe HaskellNone
LanguageHaskell98

Data.GI.CodeGen.Conversions

Synopsis

Documentation

genConversion :: Text -> Converter -> CodeGen Text Source

hToF :: Type -> Transfer -> ExcCodeGen Converter Source

fToH :: Type -> Transfer -> ExcCodeGen Converter Source

typeIsNullable :: Type -> CodeGen Bool Source

Returns whether the given type should be represented by a Maybe type on the Haskell side. This applies to all properties which have a C representation in terms of pointers, except for G(S)Lists, for which NULL is a valid G(S)List, and raw pointers, which we just pass through to the Haskell side. Notice that introspection annotations can override this.

typeIsPtr :: Type -> CodeGen Bool Source

Returns whether the given type is represented by a pointer on the C side.

apply :: Constructor -> Converter Source

mapC :: Constructor -> Converter Source

literal :: Constructor -> Converter Source