| |||||||||||
| |||||||||||
Description | |||||||||||
This module implements unique names in Yhc.Core. Given a name, it can be dividied into [rest][digits]. The digits form a number (0 for no digits). Given a set of names, they must all represent unique numbers. | |||||||||||
Synopsis | |||||||||||
| |||||||||||
Documentation | |||||||||||
uniqueNamesNext :: [String] -> Int | |||||||||||
uniqueSplit :: String -> (String, Int) | |||||||||||
Split a name into a prefix and a unique id. 0 means no trailing number. | |||||||||||
uniqueJoin :: String -> Int -> String | |||||||||||
Given a name, and a unique id, join them together. Replaces any existing id. | |||||||||||
uniqueFuncsNext :: Core -> Int | |||||||||||
uniqueFuncsSplit :: (FuncsSplitM CoreFuncName -> (CoreFunc -> FuncsSplitM ()) -> CoreExpr -> FuncsSplitM CoreExpr) -> Core -> Core | |||||||||||
A more advanced combinator to capture the pattern of splitting one function into many (i.e. recursive let's, lambda lifting) Needs rank-2 types to do properly | |||||||||||
uniqueFuncsRename :: Core -> Core | |||||||||||
Rename functions so they use consecutive numbers starting at 2, to aid human understanding | |||||||||||
Produced by Haddock version 0.8 |