Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data NameSegment
- toUnescapedText :: NameSegment -> Text
- defaultPatchSegment :: NameSegment
- docSegment :: NameSegment
- libSegment :: NameSegment
- pattern LibSegment :: NameSegment
- publicLooseCodeSegment :: NameSegment
- baseSegment :: NameSegment
- snocSegment :: NameSegment
- consSegment :: NameSegment
- concatSegment :: NameSegment
- watchSegment :: NameSegment
- setSegment :: NameSegment
- modifySegment :: NameSegment
- licenseSegment :: NameSegment
- metadataSegment :: NameSegment
- authorsSegment :: NameSegment
- copyrightHoldersSegment :: NameSegment
- guidSegment :: NameSegment
- builtinSegment :: NameSegment
Documentation
data NameSegment Source #
Represents the parts of a name between the .
s.
Instances
toUnescapedText :: NameSegment -> Text Source #
Convert a name segment to unescaped text.
You might use this when storing a name segment as text in a database, where the literal name segment bytes are all that matter. However, you wouldn't use this to display the name segment to a user - that depends on concrete syntax. See Unison.Syntax.NameSegment (or indeed, some actual yet-built interface that abstracts concrete syntax) for that kind of function.
toUnescapedText (unsafeFromText ".~") = ".~"
Sentinel name segments
pattern LibSegment :: NameSegment Source #