- data Pos = Pos !Symbol !Int !Int !Int
- posFile :: Pos -> String
- posLine :: Pos -> Int
- posCol :: Pos -> Int
- posCoff :: Pos -> Int
- startPos :: String -> Pos
- linePos :: String -> Int -> Pos
- advancePos :: Pos -> Char -> Pos
- data Loc
- locStart :: Loc -> Loc
- locEnd :: Loc -> Loc
- noLoc :: Location a => a
- newtype SrcLoc = SrcLoc Loc
- noSrcLoc :: SrcLoc
- locOf :: (Located a, Location b) => a -> b
- (<-->) :: (Located a, Located b, Location c) => a -> b -> c
- mergeLoc :: Loc -> Loc -> Loc
- class Location a where
- class Located a where
- class Relocatable a where
- data L x = L Loc x
- unLoc :: L a -> a
Location type, consisting of a beginning position and an end position.
Source location type. Source location are all equal, which allows AST nodes to be compared modulo location information.
Located values have a location.
Locations are ignored when performing comparisons.