{-# LANGUAGE DeriveDataTypeable #-}
module HPath.Internal
(Path(..))
where
import Control.DeepSeq (NFData (..))
import Data.ByteString (ByteString)
import Data.Data
data Path b = MkPath ByteString
deriving (Typeable)
instance Eq (Path b) where
== :: Path b -> Path b -> Bool
(==) (MkPath x :: ByteString
x) (MkPath y :: ByteString
y) = ByteString
x ByteString -> ByteString -> Bool
forall a. Eq a => a -> a -> Bool
== ByteString
y
instance Ord (Path b) where
compare :: Path b -> Path b -> Ordering
compare (MkPath x :: ByteString
x) (MkPath y :: ByteString
y) = ByteString -> ByteString -> Ordering
forall a. Ord a => a -> a -> Ordering
compare ByteString
x ByteString
y
instance Show (Path b) where
show :: Path b -> String
show (MkPath x :: ByteString
x) = ByteString -> String
forall a. Show a => a -> String
show ByteString
x
instance NFData (Path b) where
rnf :: Path b -> ()
rnf (MkPath x :: ByteString
x) = ByteString -> ()
forall a. NFData a => a -> ()
rnf ByteString
x