packages feed

document-build-0.2.0.0: src/Document/Build/Name/ContextProject.hs

{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -Wall #-}

{- | The name @contextProject@, targeting 'String': the path of the project of a build, such as @"group/project"@.

Any value of the target type has the name, as the identity.

@since 0.2.0.0
-}
module Document.Build.Name.ContextProject (
  ContextProjectLike (..),
) where

import Control.Lens (Optic)

{- | A field or a constructor named @contextProject@.

@since 0.2.0.0
-}
class ContextProjectLike p f x x' where
  contextProject ::
    Optic p f x x' String String

{- | Identity

@since 0.2.0.0
-}
instance (x' ~ String) => ContextProjectLike p f String x' where
  contextProject =
    id
  {-# INLINE contextProject #-}