{-# language CPP #-}
module Vulkan.Extensions.VK_EXT_validation_flags  ( ValidationFlagsEXT(..)
                                                  , ValidationCheckEXT( VALIDATION_CHECK_ALL_EXT
                                                                      , VALIDATION_CHECK_SHADERS_EXT
                                                                      , ..
                                                                      )
                                                  , EXT_VALIDATION_FLAGS_SPEC_VERSION
                                                  , pattern EXT_VALIDATION_FLAGS_SPEC_VERSION
                                                  , EXT_VALIDATION_FLAGS_EXTENSION_NAME
                                                  , pattern EXT_VALIDATION_FLAGS_EXTENSION_NAME
                                                  ) where

import Foreign.Marshal.Alloc (allocaBytesAligned)
import Foreign.Ptr (nullPtr)
import Foreign.Ptr (plusPtr)
import GHC.Read (choose)
import GHC.Read (expectP)
import GHC.Read (parens)
import GHC.Show (showParen)
import GHC.Show (showString)
import GHC.Show (showsPrec)
import Text.ParserCombinators.ReadPrec ((+++))
import Text.ParserCombinators.ReadPrec (prec)
import Text.ParserCombinators.ReadPrec (step)
import Control.Monad.Trans.Class (lift)
import Control.Monad.Trans.Cont (evalContT)
import Data.Vector (generateM)
import qualified Data.Vector (imapM_)
import qualified Data.Vector (length)
import Data.String (IsString)
import Data.Typeable (Typeable)
import Foreign.Storable (Storable)
import Foreign.Storable (Storable(peek))
import Foreign.Storable (Storable(poke))
import Data.Int (Int32)
import Foreign.Ptr (Ptr)
import GHC.Read (Read(readPrec))
import Data.Word (Word32)
import Text.Read.Lex (Lexeme(Ident))
import Data.Kind (Type)
import Control.Monad.Trans.Cont (ContT(..))
import Data.Vector (Vector)
import Vulkan.CStruct.Utils (advancePtrBytes)
import Vulkan.CStruct (FromCStruct)
import Vulkan.CStruct (FromCStruct(..))
import Vulkan.Core10.Enums.StructureType (StructureType)
import Vulkan.CStruct (ToCStruct)
import Vulkan.CStruct (ToCStruct(..))
import Vulkan.Zero (Zero)
import Vulkan.Zero (Zero(..))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_VALIDATION_FLAGS_EXT))
-- | VkValidationFlagsEXT - Specify validation checks to disable for a Vulkan
-- instance
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.Enums.StructureType.StructureType', 'ValidationCheckEXT'
data ValidationFlagsEXT = ValidationFlagsEXT
  { -- | @pDisabledValidationChecks@ /must/ be a valid pointer to an array of
    -- @disabledValidationCheckCount@ valid 'ValidationCheckEXT' values
    ValidationFlagsEXT -> Vector ValidationCheckEXT
disabledValidationChecks :: Vector ValidationCheckEXT }
  deriving (Typeable)
deriving instance Show ValidationFlagsEXT

instance ToCStruct ValidationFlagsEXT where
  withCStruct :: ValidationFlagsEXT -> (Ptr ValidationFlagsEXT -> IO b) -> IO b
withCStruct x :: ValidationFlagsEXT
x f :: Ptr ValidationFlagsEXT -> IO b
f = Int -> Int -> (Ptr ValidationFlagsEXT -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 32 8 ((Ptr ValidationFlagsEXT -> IO b) -> IO b)
-> (Ptr ValidationFlagsEXT -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr ValidationFlagsEXT
p -> Ptr ValidationFlagsEXT -> ValidationFlagsEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr ValidationFlagsEXT
p ValidationFlagsEXT
x (Ptr ValidationFlagsEXT -> IO b
f Ptr ValidationFlagsEXT
p)
  pokeCStruct :: Ptr ValidationFlagsEXT -> ValidationFlagsEXT -> IO b -> IO b
pokeCStruct p :: Ptr ValidationFlagsEXT
p ValidationFlagsEXT{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_VALIDATION_FLAGS_EXT)
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) ((Int -> Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector ValidationCheckEXT -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ValidationCheckEXT -> Int)
-> Vector ValidationCheckEXT -> Int
forall a b. (a -> b) -> a -> b
$ (Vector ValidationCheckEXT
disabledValidationChecks)) :: Word32))
    Ptr ValidationCheckEXT
pPDisabledValidationChecks' <- ((Ptr ValidationCheckEXT -> IO b) -> IO b)
-> ContT b IO (Ptr ValidationCheckEXT)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ValidationCheckEXT -> IO b) -> IO b)
 -> ContT b IO (Ptr ValidationCheckEXT))
-> ((Ptr ValidationCheckEXT -> IO b) -> IO b)
-> ContT b IO (Ptr ValidationCheckEXT)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ValidationCheckEXT -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @ValidationCheckEXT ((Vector ValidationCheckEXT -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ValidationCheckEXT
disabledValidationChecks)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ValidationCheckEXT -> IO ())
-> Vector ValidationCheckEXT -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: ValidationCheckEXT
e -> Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ValidationCheckEXT
pPDisabledValidationChecks' Ptr ValidationCheckEXT -> Int -> Ptr ValidationCheckEXT
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr ValidationCheckEXT) (ValidationCheckEXT
e)) (Vector ValidationCheckEXT
disabledValidationChecks)
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ValidationCheckEXT) -> Ptr ValidationCheckEXT -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr (Ptr ValidationCheckEXT)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ValidationCheckEXT))) (Ptr ValidationCheckEXT
pPDisabledValidationChecks')
    IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
  cStructSize :: Int
cStructSize = 32
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr ValidationFlagsEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr ValidationFlagsEXT
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_VALIDATION_FLAGS_EXT)
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr ValidationCheckEXT
pPDisabledValidationChecks' <- ((Ptr ValidationCheckEXT -> IO b) -> IO b)
-> ContT b IO (Ptr ValidationCheckEXT)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ValidationCheckEXT -> IO b) -> IO b)
 -> ContT b IO (Ptr ValidationCheckEXT))
-> ((Ptr ValidationCheckEXT -> IO b) -> IO b)
-> ContT b IO (Ptr ValidationCheckEXT)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ValidationCheckEXT -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @ValidationCheckEXT ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ValidationCheckEXT -> IO ())
-> Vector ValidationCheckEXT -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: ValidationCheckEXT
e -> Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ValidationCheckEXT
pPDisabledValidationChecks' Ptr ValidationCheckEXT -> Int -> Ptr ValidationCheckEXT
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr ValidationCheckEXT) (ValidationCheckEXT
e)) (Vector ValidationCheckEXT
forall a. Monoid a => a
mempty)
    IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ValidationCheckEXT) -> Ptr ValidationCheckEXT -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr (Ptr ValidationCheckEXT)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ValidationCheckEXT))) (Ptr ValidationCheckEXT
pPDisabledValidationChecks')
    IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f

instance FromCStruct ValidationFlagsEXT where
  peekCStruct :: Ptr ValidationFlagsEXT -> IO ValidationFlagsEXT
peekCStruct p :: Ptr ValidationFlagsEXT
p = do
    Word32
disabledValidationCheckCount <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
    Ptr ValidationCheckEXT
pDisabledValidationChecks <- Ptr (Ptr ValidationCheckEXT) -> IO (Ptr ValidationCheckEXT)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr ValidationCheckEXT) ((Ptr ValidationFlagsEXT
p Ptr ValidationFlagsEXT -> Int -> Ptr (Ptr ValidationCheckEXT)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ValidationCheckEXT)))
    Vector ValidationCheckEXT
pDisabledValidationChecks' <- Int
-> (Int -> IO ValidationCheckEXT) -> IO (Vector ValidationCheckEXT)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (Word32 -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral Word32
disabledValidationCheckCount) (\i :: Int
i -> Ptr ValidationCheckEXT -> IO ValidationCheckEXT
forall a. Storable a => Ptr a -> IO a
peek @ValidationCheckEXT ((Ptr ValidationCheckEXT
pDisabledValidationChecks Ptr ValidationCheckEXT -> Int -> Ptr ValidationCheckEXT
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr ValidationCheckEXT)))
    ValidationFlagsEXT -> IO ValidationFlagsEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (ValidationFlagsEXT -> IO ValidationFlagsEXT)
-> ValidationFlagsEXT -> IO ValidationFlagsEXT
forall a b. (a -> b) -> a -> b
$ Vector ValidationCheckEXT -> ValidationFlagsEXT
ValidationFlagsEXT
             Vector ValidationCheckEXT
pDisabledValidationChecks'

instance Zero ValidationFlagsEXT where
  zero :: ValidationFlagsEXT
zero = Vector ValidationCheckEXT -> ValidationFlagsEXT
ValidationFlagsEXT
           Vector ValidationCheckEXT
forall a. Monoid a => a
mempty


-- | VkValidationCheckEXT - Specify validation checks to disable
--
-- = See Also
--
-- 'ValidationFlagsEXT'
newtype ValidationCheckEXT = ValidationCheckEXT Int32
  deriving newtype (ValidationCheckEXT -> ValidationCheckEXT -> Bool
(ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> (ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> Eq ValidationCheckEXT
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c/= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
== :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c== :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
Eq, Eq ValidationCheckEXT
Eq ValidationCheckEXT =>
(ValidationCheckEXT -> ValidationCheckEXT -> Ordering)
-> (ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> (ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> (ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> (ValidationCheckEXT -> ValidationCheckEXT -> Bool)
-> (ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT)
-> (ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT)
-> Ord ValidationCheckEXT
ValidationCheckEXT -> ValidationCheckEXT -> Bool
ValidationCheckEXT -> ValidationCheckEXT -> Ordering
ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT
$cmin :: ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT
max :: ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT
$cmax :: ValidationCheckEXT -> ValidationCheckEXT -> ValidationCheckEXT
>= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c>= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
> :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c> :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
<= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c<= :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
< :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
$c< :: ValidationCheckEXT -> ValidationCheckEXT -> Bool
compare :: ValidationCheckEXT -> ValidationCheckEXT -> Ordering
$ccompare :: ValidationCheckEXT -> ValidationCheckEXT -> Ordering
$cp1Ord :: Eq ValidationCheckEXT
Ord, Ptr b -> Int -> IO ValidationCheckEXT
Ptr b -> Int -> ValidationCheckEXT -> IO ()
Ptr ValidationCheckEXT -> IO ValidationCheckEXT
Ptr ValidationCheckEXT -> Int -> IO ValidationCheckEXT
Ptr ValidationCheckEXT -> Int -> ValidationCheckEXT -> IO ()
Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ()
ValidationCheckEXT -> Int
(ValidationCheckEXT -> Int)
-> (ValidationCheckEXT -> Int)
-> (Ptr ValidationCheckEXT -> Int -> IO ValidationCheckEXT)
-> (Ptr ValidationCheckEXT -> Int -> ValidationCheckEXT -> IO ())
-> (forall b. Ptr b -> Int -> IO ValidationCheckEXT)
-> (forall b. Ptr b -> Int -> ValidationCheckEXT -> IO ())
-> (Ptr ValidationCheckEXT -> IO ValidationCheckEXT)
-> (Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ())
-> Storable ValidationCheckEXT
forall b. Ptr b -> Int -> IO ValidationCheckEXT
forall b. Ptr b -> Int -> ValidationCheckEXT -> IO ()
forall a.
(a -> Int)
-> (a -> Int)
-> (Ptr a -> Int -> IO a)
-> (Ptr a -> Int -> a -> IO ())
-> (forall b. Ptr b -> Int -> IO a)
-> (forall b. Ptr b -> Int -> a -> IO ())
-> (Ptr a -> IO a)
-> (Ptr a -> a -> IO ())
-> Storable a
poke :: Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ()
$cpoke :: Ptr ValidationCheckEXT -> ValidationCheckEXT -> IO ()
peek :: Ptr ValidationCheckEXT -> IO ValidationCheckEXT
$cpeek :: Ptr ValidationCheckEXT -> IO ValidationCheckEXT
pokeByteOff :: Ptr b -> Int -> ValidationCheckEXT -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> ValidationCheckEXT -> IO ()
peekByteOff :: Ptr b -> Int -> IO ValidationCheckEXT
$cpeekByteOff :: forall b. Ptr b -> Int -> IO ValidationCheckEXT
pokeElemOff :: Ptr ValidationCheckEXT -> Int -> ValidationCheckEXT -> IO ()
$cpokeElemOff :: Ptr ValidationCheckEXT -> Int -> ValidationCheckEXT -> IO ()
peekElemOff :: Ptr ValidationCheckEXT -> Int -> IO ValidationCheckEXT
$cpeekElemOff :: Ptr ValidationCheckEXT -> Int -> IO ValidationCheckEXT
alignment :: ValidationCheckEXT -> Int
$calignment :: ValidationCheckEXT -> Int
sizeOf :: ValidationCheckEXT -> Int
$csizeOf :: ValidationCheckEXT -> Int
Storable, ValidationCheckEXT
ValidationCheckEXT -> Zero ValidationCheckEXT
forall a. a -> Zero a
zero :: ValidationCheckEXT
$czero :: ValidationCheckEXT
Zero)

-- | 'VALIDATION_CHECK_ALL_EXT' specifies that all validation checks are
-- disabled.
pattern $bVALIDATION_CHECK_ALL_EXT :: ValidationCheckEXT
$mVALIDATION_CHECK_ALL_EXT :: forall r. ValidationCheckEXT -> (Void# -> r) -> (Void# -> r) -> r
VALIDATION_CHECK_ALL_EXT = ValidationCheckEXT 0
-- | 'VALIDATION_CHECK_SHADERS_EXT' specifies that shader validation is
-- disabled.
pattern $bVALIDATION_CHECK_SHADERS_EXT :: ValidationCheckEXT
$mVALIDATION_CHECK_SHADERS_EXT :: forall r. ValidationCheckEXT -> (Void# -> r) -> (Void# -> r) -> r
VALIDATION_CHECK_SHADERS_EXT = ValidationCheckEXT 1
{-# complete VALIDATION_CHECK_ALL_EXT,
             VALIDATION_CHECK_SHADERS_EXT :: ValidationCheckEXT #-}

instance Show ValidationCheckEXT where
  showsPrec :: Int -> ValidationCheckEXT -> ShowS
showsPrec p :: Int
p = \case
    VALIDATION_CHECK_ALL_EXT -> String -> ShowS
showString "VALIDATION_CHECK_ALL_EXT"
    VALIDATION_CHECK_SHADERS_EXT -> String -> ShowS
showString "VALIDATION_CHECK_SHADERS_EXT"
    ValidationCheckEXT x :: Int32
x -> Bool -> ShowS -> ShowS
showParen (Int
p Int -> Int -> Bool
forall a. Ord a => a -> a -> Bool
>= 11) (String -> ShowS
showString "ValidationCheckEXT " ShowS -> ShowS -> ShowS
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Int -> Int32 -> ShowS
forall a. Show a => Int -> a -> ShowS
showsPrec 11 Int32
x)

instance Read ValidationCheckEXT where
  readPrec :: ReadPrec ValidationCheckEXT
readPrec = ReadPrec ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall a. ReadPrec a -> ReadPrec a
parens ([(String, ReadPrec ValidationCheckEXT)]
-> ReadPrec ValidationCheckEXT
forall a. [(String, ReadPrec a)] -> ReadPrec a
choose [("VALIDATION_CHECK_ALL_EXT", ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure ValidationCheckEXT
VALIDATION_CHECK_ALL_EXT)
                            , ("VALIDATION_CHECK_SHADERS_EXT", ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure ValidationCheckEXT
VALIDATION_CHECK_SHADERS_EXT)]
                     ReadPrec ValidationCheckEXT
-> ReadPrec ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall a. ReadPrec a -> ReadPrec a -> ReadPrec a
+++
                     Int -> ReadPrec ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall a. Int -> ReadPrec a -> ReadPrec a
prec 10 (do
                       Lexeme -> ReadPrec ()
expectP (String -> Lexeme
Ident "ValidationCheckEXT")
                       Int32
v <- ReadPrec Int32 -> ReadPrec Int32
forall a. ReadPrec a -> ReadPrec a
step ReadPrec Int32
forall a. Read a => ReadPrec a
readPrec
                       ValidationCheckEXT -> ReadPrec ValidationCheckEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Int32 -> ValidationCheckEXT
ValidationCheckEXT Int32
v)))


type EXT_VALIDATION_FLAGS_SPEC_VERSION = 2

-- No documentation found for TopLevel "VK_EXT_VALIDATION_FLAGS_SPEC_VERSION"
pattern EXT_VALIDATION_FLAGS_SPEC_VERSION :: forall a . Integral a => a
pattern $bEXT_VALIDATION_FLAGS_SPEC_VERSION :: a
$mEXT_VALIDATION_FLAGS_SPEC_VERSION :: forall r a. Integral a => a -> (Void# -> r) -> (Void# -> r) -> r
EXT_VALIDATION_FLAGS_SPEC_VERSION = 2


type EXT_VALIDATION_FLAGS_EXTENSION_NAME = "VK_EXT_validation_flags"

-- No documentation found for TopLevel "VK_EXT_VALIDATION_FLAGS_EXTENSION_NAME"
pattern EXT_VALIDATION_FLAGS_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bEXT_VALIDATION_FLAGS_EXTENSION_NAME :: a
$mEXT_VALIDATION_FLAGS_EXTENSION_NAME :: forall r a.
(Eq a, IsString a) =>
a -> (Void# -> r) -> (Void# -> r) -> r
EXT_VALIDATION_FLAGS_EXTENSION_NAME = "VK_EXT_validation_flags"