module CabalGild.Extra.Name where

import qualified Distribution.Fields as Fields

-- | Extracts the annotation from the given 'Fields.Name'.
annotation :: Fields.Name a -> a
annotation :: forall a. Name a -> a
annotation (Fields.Name a
x FieldName
_) = a
x

-- | Extracts the value from the given 'Fields.Name'.
value :: Fields.Name a -> Fields.FieldName
value :: forall a. Name a -> FieldName
value (Fields.Name a
_ FieldName
x) = FieldName
x