Copyright | Christian Maeder and Uni Bremen 2006 |
---|---|
License | GPLv2 or higher, see LICENSE.txt |
Maintainer | Christian.Maeder@dfki.de |
Stability | experimental |
Portability | portable |
Safe Haskell | Safe-Inferred |
Precedence checking
- data PrecMap = PrecMap {}
- emptyPrecMap :: PrecMap
- mkPrecIntMap :: Rel Id -> PrecMap
- getIdPrec :: PrecMap -> Set Id -> Id -> Int
- getSimpleIdPrec :: PrecMap -> Id -> Int
- dropPrefix :: [a] -> [b] -> [b]
- isLeftArg :: Id -> [a] -> Bool
- isRightArg :: Id -> [a] -> Bool
- joinPlace :: AssocEither -> Id -> Bool
- checkArg :: AssocEither -> GlobalAnnos -> (Id, Int) -> (Id, Int) -> Id -> Bool
- nextWeight :: AssocEither -> GlobalAnnos -> Id -> Id -> Id
- checkPrec :: GlobalAnnos -> (Id, Int) -> (Id, Int) -> [a] -> (AssocEither -> Id) -> Bool
- typeInstTok :: Token
- polyId :: Id -> Id
- unPolyId :: Id -> Maybe Id
- stripPoly :: Id -> Id
- getGenPolyTokenList :: String -> Id -> [Token]
Documentation
data PrecMap
a precedence map using numbers for faster lookup
mkPrecIntMap :: Rel Id -> PrecMap
getSimpleIdPrec :: PrecMap -> Id -> Int
dropPrefix :: [a] -> [b] -> [b]
drop as many elements as are in the first list
isLeftArg :: Id -> [a] -> Bool
check if a left argument will be added.
(The Int
is the number of current arguments.)
isRightArg :: Id -> [a] -> Bool
check if a right argument will be added.
joinPlace :: AssocEither -> Id -> Bool
checkArg :: AssocEither -> GlobalAnnos -> (Id, Int) -> (Id, Int) -> Id -> Bool
nextWeight :: AssocEither -> GlobalAnnos -> Id -> Id -> Id
compute the left or right weight for the application
checkPrec :: GlobalAnnos -> (Id, Int) -> (Id, Int) -> [a] -> (AssocEither -> Id) -> Bool
check precedence of an argument and a top-level operator.
typeInstTok :: Token
token for instantiation lists of polymorphic operations
mark an identifier as polymorphic with a typeInstTok
token
remove the typeInstTok
token again
getGenPolyTokenList :: String -> Id -> [Token]
get the token lists for polymorphic ids