haskus-binary-1.2: Haskus binary format manipulation

Safe HaskellNone
LanguageHaskell2010

Haskus.Format.Binary.Layout

Description

Memory layout

Describe a memory region

Synopsis

Documentation

type family LayoutPathType l p :: * Source #

Type obtained when following path p

Instances
type LayoutPathType l (LayoutPath ([] :: [Type])) Source # 
Instance details

Defined in Haskus.Format.Binary.Layout

type LayoutPathType l (LayoutPath ([] :: [Type])) = l

type family LayoutPathOffset l p :: Nat Source #

Offset obtained when following path p

Instances
type LayoutPathOffset e (LayoutPath ([] :: [Type])) Source # 
Instance details

Defined in Haskus.Format.Binary.Layout

type LayoutPathOffset e (LayoutPath ([] :: [Type])) = 0

data LayoutPath (path :: [*]) Source #

Path in a layout

Constructors

LayoutPath 
Instances
type LayoutPathOffset e (LayoutPath ([] :: [Type])) Source # 
Instance details

Defined in Haskus.Format.Binary.Layout

type LayoutPathOffset e (LayoutPath ([] :: [Type])) = 0
type LayoutPathType l (LayoutPath ([] :: [Type])) Source # 
Instance details

Defined in Haskus.Format.Binary.Layout

type LayoutPathType l (LayoutPath ([] :: [Type])) = l

data LayoutIndex (n :: Nat) Source #

Index in a layout path

Constructors

LayoutIndex 

data LayoutSymbol (s :: Symbol) Source #

Symbol in a layout path

Constructors

LayoutSymbol 

layoutIndex :: forall n. LayoutPath '[LayoutIndex n] Source #

Index in the layout path

layoutSymbol :: forall s. LayoutPath '[LayoutSymbol s] Source #

Symbol in the layout path

type family p :-> (s :: Symbol) where ... Source #

Equations

(LayoutPath xs) :-> s = LayoutPath (Snoc xs (LayoutSymbol s)) 

type family p :#> (n :: Nat) where ... Source #

Equations

(LayoutPath xs) :#> n = LayoutPath (Snoc xs (LayoutIndex n))