packages feed

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

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

{- | The name @inputFileCount@, targeting 'Int': the number of input files that a directory has.

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

@since 0.2.0.0
-}
module Document.Build.Name.InputFileCount (
  InputFileCountLike (..),
) where

import Control.Lens (Optic)

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

@since 0.2.0.0
-}
class InputFileCountLike p f x x' where
  inputFileCount ::
    Optic p f x x' Int Int

{- | Identity

@since 0.2.0.0
-}
instance (x' ~ Int) => InputFileCountLike p f Int x' where
  inputFileCount =
    id
  {-# INLINE inputFileCount #-}