Improve documentation
This commit is contained in:
parent
7b66379d49
commit
607e67378c
@ -31,7 +31,7 @@ module HPath
|
|||||||
-- * PatternSynonyms/ViewPatterns
|
-- * PatternSynonyms/ViewPatterns
|
||||||
,pattern Path
|
,pattern Path
|
||||||
#endif
|
#endif
|
||||||
-- * Path Parsing
|
-- * Path Construction
|
||||||
,parseAbs
|
,parseAbs
|
||||||
,parseRel
|
,parseRel
|
||||||
,parseAny
|
,parseAny
|
||||||
|
@ -10,15 +10,19 @@ import Control.DeepSeq (NFData (..))
|
|||||||
import Data.ByteString (ByteString)
|
import Data.ByteString (ByteString)
|
||||||
import Data.Data
|
import Data.Data
|
||||||
|
|
||||||
-- | Path of some base and type.
|
-- | The main Path type.
|
||||||
--
|
--
|
||||||
-- Internally is a ByteString. The ByteString can be of two formats only:
|
-- The type variable 'b' is either:
|
||||||
--
|
--
|
||||||
-- 1. without trailing path separator: @file.txt@, @foo\/bar.txt@, @\/foo\/bar.txt@
|
-- * Abs -- absolute path
|
||||||
-- 2. with trailing path separator: @foo\/@, @\/foo\/bar\/@
|
-- * Rel -- relative path
|
||||||
--
|
--
|
||||||
-- There are no duplicate
|
-- Internally is a ByteString. The path is guaranteed to
|
||||||
-- path separators @\/\/@, no @..@, no @.\/@, no @~\/@, etc.
|
-- be normalised and contain no trailing Path separators,
|
||||||
|
-- except for the '/' root path.
|
||||||
|
--
|
||||||
|
-- There are no duplicate path separators
|
||||||
|
-- @\/\/@, no @..@, no @.\/@, no @~\/@, etc.
|
||||||
data Path b = MkPath ByteString
|
data Path b = MkPath ByteString
|
||||||
deriving (Typeable)
|
deriving (Typeable)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user