{-# LANGUAGE ForeignFunctionInterface #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE NoFieldSelectors #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_HADDOCK prune #-}
module SDL3.Sys.Bindgen.Log.Safe (
SDL3.Sys.Bindgen.Log.Safe.sDL_SetLogPriorities,
SDL3.Sys.Bindgen.Log.Safe.sDL_SetLogPriority,
SDL3.Sys.Bindgen.Log.Safe.sDL_GetLogPriority,
SDL3.Sys.Bindgen.Log.Safe.sDL_ResetLogPriorities,
SDL3.Sys.Bindgen.Log.Safe.sDL_SetLogPriorityPrefix,
SDL3.Sys.Bindgen.Log.Safe.sDL_GetDefaultLogOutputFunction,
SDL3.Sys.Bindgen.Log.Safe.sDL_GetLogOutputFunction,
SDL3.Sys.Bindgen.Log.Safe.sDL_SetLogOutputFunction,
)
where
import Prelude (IO, fmap)
import HsBindgen.Runtime.PtrConst qualified as PtrConst
import HsBindgen.Runtime.Support qualified as BG
import HsBindgen.Runtime.Support.CAPI qualified
import SDL3.Sys.Bindgen.Log
$( HsBindgen.Runtime.Support.CAPI.addCSource
( HsBindgen.Runtime.Support.CAPI.unlines
[ "#define SDL_MAIN_HANDLED"
, "#define SDL_SLOW_MEMCPY"
, "#define SDL_SLOW_MEMMOVE"
, "#define SDL_SLOW_MEMSET"
, "#include <SDL3/SDL_log.h>"
, "void hs_bindgen_f2fe4ac03d85bd48 ("
, " SDL_LogPriority arg1"
, ")"
, "{"
, " (SDL_SetLogPriorities)(arg1);"
, "}"
, "void hs_bindgen_3ebd8c186ab4d36e ("
, " signed int arg1,"
, " SDL_LogPriority arg2"
, ")"
, "{"
, " (SDL_SetLogPriority)(arg1, arg2);"
, "}"
, "SDL_LogPriority hs_bindgen_ba1c5f57ea908831 ("
, " signed int arg1"
, ")"
, "{"
, " return (SDL_GetLogPriority)(arg1);"
, "}"
, "void hs_bindgen_6d6b388f10a6a765 (void)"
, "{"
, " (SDL_ResetLogPriorities)();"
, "}"
, "_Bool hs_bindgen_a2865e2847033be6 ("
, " SDL_LogPriority arg1,"
, " char const *arg2"
, ")"
, "{"
, " return (SDL_SetLogPriorityPrefix)(arg1, arg2);"
, "}"
, "SDL_LogOutputFunction hs_bindgen_29e148c925d2e14a (void)"
, "{"
, " return (SDL_GetDefaultLogOutputFunction)();"
, "}"
, "void hs_bindgen_50b31a8317423d85 ("
, " SDL_LogOutputFunction *arg1,"
, " void **arg2"
, ")"
, "{"
, " (SDL_GetLogOutputFunction)(arg1, arg2);"
, "}"
, "void hs_bindgen_bef3e6ff73c88ce8 ("
, " SDL_LogOutputFunction arg1,"
, " void *arg2"
, ")"
, "{"
, " (SDL_SetLogOutputFunction)(arg1, arg2);"
, "}"
]
)
)
foreign import ccall safe "hs_bindgen_f2fe4ac03d85bd48"
hs_bindgen_f2fe4ac03d85bd48_base
:: BG.CUInt
-> IO ()
hs_bindgen_f2fe4ac03d85bd48
:: SDL_LogPriority
-> IO ()
hs_bindgen_f2fe4ac03d85bd48 :: SDL_LogPriority -> IO ()
hs_bindgen_f2fe4ac03d85bd48 =
\SDL_LogPriority
x0 ->
CUInt -> IO ()
hs_bindgen_f2fe4ac03d85bd48_base (SDL_LogPriority -> FFIType SDL_LogPriority
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_LogPriority
x0)
sDL_SetLogPriorities
:: SDL_LogPriority
-> IO ()
sDL_SetLogPriorities :: SDL_LogPriority -> IO ()
sDL_SetLogPriorities = SDL_LogPriority -> IO ()
hs_bindgen_f2fe4ac03d85bd48
foreign import ccall safe "hs_bindgen_3ebd8c186ab4d36e"
hs_bindgen_3ebd8c186ab4d36e_base
:: BG.CInt
-> BG.CUInt
-> IO ()
hs_bindgen_3ebd8c186ab4d36e
:: BG.CInt
-> SDL_LogPriority
-> IO ()
hs_bindgen_3ebd8c186ab4d36e :: CInt -> SDL_LogPriority -> IO ()
hs_bindgen_3ebd8c186ab4d36e =
\CInt
x0 ->
\SDL_LogPriority
x1 ->
CInt -> CUInt -> IO ()
hs_bindgen_3ebd8c186ab4d36e_base (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x0) (SDL_LogPriority -> FFIType SDL_LogPriority
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_LogPriority
x1)
sDL_SetLogPriority
:: BG.CInt
-> SDL_LogPriority
-> IO ()
sDL_SetLogPriority :: CInt -> SDL_LogPriority -> IO ()
sDL_SetLogPriority = CInt -> SDL_LogPriority -> IO ()
hs_bindgen_3ebd8c186ab4d36e
foreign import ccall safe "hs_bindgen_ba1c5f57ea908831"
hs_bindgen_ba1c5f57ea908831_base
:: BG.CInt
-> IO BG.CUInt
hs_bindgen_ba1c5f57ea908831
:: BG.CInt
-> IO SDL_LogPriority
hs_bindgen_ba1c5f57ea908831 :: CInt -> IO SDL_LogPriority
hs_bindgen_ba1c5f57ea908831 =
\CInt
x0 ->
(CUInt -> SDL_LogPriority) -> IO CUInt -> IO SDL_LogPriority
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CUInt -> SDL_LogPriority
FFIType SDL_LogPriority -> SDL_LogPriority
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (CInt -> IO CUInt
hs_bindgen_ba1c5f57ea908831_base (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x0))
sDL_GetLogPriority
:: BG.CInt
-> IO SDL_LogPriority
sDL_GetLogPriority :: CInt -> IO SDL_LogPriority
sDL_GetLogPriority = CInt -> IO SDL_LogPriority
hs_bindgen_ba1c5f57ea908831
foreign import ccall safe "hs_bindgen_6d6b388f10a6a765"
hs_bindgen_6d6b388f10a6a765_base
:: IO ()
hs_bindgen_6d6b388f10a6a765 :: IO ()
hs_bindgen_6d6b388f10a6a765 :: IO ()
hs_bindgen_6d6b388f10a6a765 =
IO ()
hs_bindgen_6d6b388f10a6a765_base
sDL_ResetLogPriorities :: IO ()
sDL_ResetLogPriorities :: IO ()
sDL_ResetLogPriorities = IO ()
hs_bindgen_6d6b388f10a6a765
foreign import ccall safe "hs_bindgen_a2865e2847033be6"
hs_bindgen_a2865e2847033be6_base
:: BG.CUInt
-> BG.Ptr BG.Void
-> IO BG.CBool
hs_bindgen_a2865e2847033be6
:: SDL_LogPriority
-> PtrConst.PtrConst BG.CChar
-> IO BG.CBool
hs_bindgen_a2865e2847033be6 :: SDL_LogPriority -> PtrConst CChar -> IO CBool
hs_bindgen_a2865e2847033be6 =
\SDL_LogPriority
x0 ->
\PtrConst CChar
x1 ->
(CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (CUInt -> Ptr Void -> IO CBool
hs_bindgen_a2865e2847033be6_base (SDL_LogPriority -> FFIType SDL_LogPriority
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_LogPriority
x0) (PtrConst CChar -> FFIType (PtrConst CChar)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst CChar
x1))
sDL_SetLogPriorityPrefix
:: SDL_LogPriority
-> PtrConst.PtrConst BG.CChar
-> IO BG.CBool
sDL_SetLogPriorityPrefix :: SDL_LogPriority -> PtrConst CChar -> IO CBool
sDL_SetLogPriorityPrefix =
SDL_LogPriority -> PtrConst CChar -> IO CBool
hs_bindgen_a2865e2847033be6
foreign import ccall safe "hs_bindgen_29e148c925d2e14a"
hs_bindgen_29e148c925d2e14a_base
:: IO (BG.FunPtr BG.Void)
hs_bindgen_29e148c925d2e14a :: IO SDL_LogOutputFunction
hs_bindgen_29e148c925d2e14a :: IO SDL_LogOutputFunction
hs_bindgen_29e148c925d2e14a =
(FunPtr Void -> SDL_LogOutputFunction)
-> IO (FunPtr Void) -> IO SDL_LogOutputFunction
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap FunPtr Void -> SDL_LogOutputFunction
FFIType SDL_LogOutputFunction -> SDL_LogOutputFunction
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO (FunPtr Void)
hs_bindgen_29e148c925d2e14a_base
sDL_GetDefaultLogOutputFunction :: IO SDL_LogOutputFunction
sDL_GetDefaultLogOutputFunction :: IO SDL_LogOutputFunction
sDL_GetDefaultLogOutputFunction =
IO SDL_LogOutputFunction
hs_bindgen_29e148c925d2e14a
foreign import ccall safe "hs_bindgen_50b31a8317423d85"
hs_bindgen_50b31a8317423d85_base
:: BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_50b31a8317423d85
:: BG.Ptr SDL_LogOutputFunction
-> BG.Ptr (BG.Ptr BG.Void)
-> IO ()
hs_bindgen_50b31a8317423d85 :: Ptr SDL_LogOutputFunction -> Ptr (Ptr Void) -> IO ()
hs_bindgen_50b31a8317423d85 =
\Ptr SDL_LogOutputFunction
x0 ->
\Ptr (Ptr Void)
x1 ->
Ptr Void -> Ptr Void -> IO ()
hs_bindgen_50b31a8317423d85_base (Ptr SDL_LogOutputFunction -> FFIType (Ptr SDL_LogOutputFunction)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_LogOutputFunction
x0) (Ptr (Ptr Void) -> FFIType (Ptr (Ptr Void))
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr (Ptr Void)
x1)
sDL_GetLogOutputFunction
:: BG.Ptr SDL_LogOutputFunction
-> BG.Ptr (BG.Ptr BG.Void)
-> IO ()
sDL_GetLogOutputFunction :: Ptr SDL_LogOutputFunction -> Ptr (Ptr Void) -> IO ()
sDL_GetLogOutputFunction =
Ptr SDL_LogOutputFunction -> Ptr (Ptr Void) -> IO ()
hs_bindgen_50b31a8317423d85
foreign import ccall safe "hs_bindgen_bef3e6ff73c88ce8"
hs_bindgen_bef3e6ff73c88ce8_base
:: BG.FunPtr BG.Void
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_bef3e6ff73c88ce8
:: SDL_LogOutputFunction
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_bef3e6ff73c88ce8 :: SDL_LogOutputFunction -> Ptr Void -> IO ()
hs_bindgen_bef3e6ff73c88ce8 =
\SDL_LogOutputFunction
x0 ->
\Ptr Void
x1 ->
FunPtr Void -> Ptr Void -> IO ()
hs_bindgen_bef3e6ff73c88ce8_base (SDL_LogOutputFunction -> FFIType SDL_LogOutputFunction
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_LogOutputFunction
x0) (Ptr Void -> FFIType (Ptr Void)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr Void
x1)
sDL_SetLogOutputFunction
:: SDL_LogOutputFunction
-> BG.Ptr BG.Void
-> IO ()
sDL_SetLogOutputFunction :: SDL_LogOutputFunction -> Ptr Void -> IO ()
sDL_SetLogOutputFunction =
SDL_LogOutputFunction -> Ptr Void -> IO ()
hs_bindgen_bef3e6ff73c88ce8