| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Language.Haskell.Brittany
- parsePrintModule :: Config -> Text -> IO (Either [BrittanyError] Text)
- staticDefaultConfig :: Config
- forwardOptionsSyntaxExtsEnabled :: ForwardOptions
- type Config = CConfig Identity
- data CConfig f = Config {}
- data CDebugConfig f = DebugConfig {
- _dconf_dump_config :: f (Last Bool)
- _dconf_dump_annotations :: f (Last Bool)
- _dconf_dump_ast_unknown :: f (Last Bool)
- _dconf_dump_ast_full :: f (Last Bool)
- _dconf_dump_bridoc_raw :: f (Last Bool)
- _dconf_dump_bridoc_simpl_alt :: f (Last Bool)
- _dconf_dump_bridoc_simpl_floating :: f (Last Bool)
- _dconf_dump_bridoc_simpl_par :: f (Last Bool)
- _dconf_dump_bridoc_simpl_columns :: f (Last Bool)
- _dconf_dump_bridoc_simpl_indent :: f (Last Bool)
- _dconf_dump_bridoc_final :: f (Last Bool)
- _dconf_roundtrip_exactprint_only :: f (Last Bool)
- data CLayoutConfig f = LayoutConfig {
- _lconfig_cols :: f (Last Int)
- _lconfig_indentPolicy :: f (Last IndentPolicy)
- _lconfig_indentAmount :: f (Last Int)
- _lconfig_indentWhereSpecial :: f (Last Bool)
- _lconfig_indentListSpecial :: f (Last Bool)
- _lconfig_importColumn :: f (Last Int)
- _lconfig_altChooser :: f (Last AltChooser)
- _lconfig_columnAlignMode :: f (Last ColumnAlignMode)
- _lconfig_alignmentLimit :: f (Last Int)
- _lconfig_alignmentBreakOnMultiline :: f (Last Bool)
- data CErrorHandlingConfig f = ErrorHandlingConfig {}
- data CForwardOptions f = ForwardOptions {
- _options_ghc :: f [String]
- data CPreProcessorConfig f = PreProcessorConfig {
- _ppconf_CPPMode :: f (Last CPPMode)
- _ppconf_hackAroundIncludes :: f (Last Bool)
- data BrittanyError
- = ErrorInput String
- | ErrorUnusedComment String
- | LayoutWarning String
- | Data ast => ErrorUnknownNode String ast
- | ErrorOutputCheck
Documentation
parsePrintModule :: Config -> Text -> IO (Either [BrittanyError] Text) Source #
Exposes the transformation in an pseudo-pure fashion. The signature
contains IO due to the GHC API not exposing a pure parsing function, but
there should be no observable effects.
Note that this function ignores/resets all config values regarding
debugging, i.e. it will never use trace/write to stderr.
Constructors
| Config | |
Fields
| |
data CDebugConfig f Source #
Constructors
| DebugConfig | |
Fields
| |
Instances
data CLayoutConfig f Source #
Constructors
| LayoutConfig | |
Fields
| |
Instances
data CErrorHandlingConfig f Source #
Constructors
| ErrorHandlingConfig | |
Fields
| |
Instances
data CForwardOptions f Source #
Constructors
| ForwardOptions | |
Fields
| |
Instances
data CPreProcessorConfig f Source #
Constructors
| PreProcessorConfig | |
Fields
| |
Instances
data BrittanyError Source #
Constructors
| ErrorInput String | parsing failed |
| ErrorUnusedComment String | internal error: some comment went missing |
| LayoutWarning String | some warning |
| Data ast => ErrorUnknownNode String ast | internal error: pretty-printing is not implemented for type of node in the syntax-tree |
| ErrorOutputCheck | checking the output for syntactic validity failed |