filepather-0.8.0.0: src/System/FilePather/Name/Steps.hs
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -Wall #-}
{- | The name @steps@, targeting @['System.FilePather.Step.Step']@: the steps of a trail, nearest first.
Any value of the target type has the name, as the identity.
@since 0.8.0.0
-}
module System.FilePather.Name.Steps (
StepsLike (..),
) where
import Control.Lens (Optic)
import System.FilePather.Step (Step)
{- | A field or a constructor named @steps@.
@since 0.8.0.0
-}
class StepsLike p f x x' where
steps ::
Optic p f x x' [Step] [Step]
{- | Identity
@since 0.8.0.0
-}
instance (x' ~ [Step]) => StepsLike p f [Step] x' where
steps =
id
{-# INLINE steps #-}