{-# LINE 1 "Network/Socket/Flag.hsc" #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE PatternSynonyms #-}
module Network.Socket.Flag where
import qualified Data.Semigroup as Sem
import Network.Socket.Imports
newtype MsgFlag = MsgFlag { fromMsgFlag :: CInt }
deriving (Show, Eq, Ord, Num, Bits)
instance Sem.Semigroup MsgFlag where
(<>) = (.|.)
instance Monoid MsgFlag where
mempty = MsgFlag 0
{-# LINE 31 "Network/Socket/Flag.hsc" #-}
pattern MSG_OOB :: MsgFlag
{-# LINE 35 "Network/Socket/Flag.hsc" #-}
pattern MSG_OOB = MsgFlag (1)
{-# LINE 36 "Network/Socket/Flag.hsc" #-}
{-# LINE 39 "Network/Socket/Flag.hsc" #-}
pattern MSG_DONTROUTE :: MsgFlag
{-# LINE 43 "Network/Socket/Flag.hsc" #-}
pattern MSG_DONTROUTE = MsgFlag (4)
{-# LINE 44 "Network/Socket/Flag.hsc" #-}
{-# LINE 47 "Network/Socket/Flag.hsc" #-}
pattern MSG_PEEK :: MsgFlag
{-# LINE 51 "Network/Socket/Flag.hsc" #-}
pattern MSG_PEEK = MsgFlag (2)
{-# LINE 52 "Network/Socket/Flag.hsc" #-}
{-# LINE 55 "Network/Socket/Flag.hsc" #-}
pattern MSG_EOR :: MsgFlag
{-# LINE 59 "Network/Socket/Flag.hsc" #-}
pattern MSG_EOR = MsgFlag (8)
{-# LINE 60 "Network/Socket/Flag.hsc" #-}
{-# LINE 63 "Network/Socket/Flag.hsc" #-}
pattern MSG_TRUNC :: MsgFlag
{-# LINE 67 "Network/Socket/Flag.hsc" #-}
pattern MSG_TRUNC = MsgFlag (16)
{-# LINE 68 "Network/Socket/Flag.hsc" #-}
{-# LINE 71 "Network/Socket/Flag.hsc" #-}
pattern MSG_CTRUNC :: MsgFlag
{-# LINE 75 "Network/Socket/Flag.hsc" #-}
pattern MSG_CTRUNC = MsgFlag (32)
{-# LINE 76 "Network/Socket/Flag.hsc" #-}
{-# LINE 79 "Network/Socket/Flag.hsc" #-}
pattern MSG_WAITALL :: MsgFlag
{-# LINE 83 "Network/Socket/Flag.hsc" #-}
pattern MSG_WAITALL = MsgFlag (64)
{-# LINE 84 "Network/Socket/Flag.hsc" #-}
{-# LINE 87 "Network/Socket/Flag.hsc" #-}