Safe Haskell | None |
---|---|
Language | Haskell2010 |
Formatting type declarations and class instances for inferred types.
Synopsis
- displaySplitTypes :: Map Text Type -> Text
- normalizeTypeName :: Text -> Text
Documentation
normalizeTypeName :: Text -> Text Source #
Normalize type name by: 1. Treating all characters that are not acceptable in Haskell variable name as end of word. 2. Capitalizing each word, but a first (camelCase). 3. Adding underscore if first character is non-alphabetic. 4. Escaping Haskell keywords if the whole identifier is such keyword. 5. If identifier is empty, then substituting JsonEmptyKey for its name.