Copyright | License : BSD3 |
---|---|
Maintainer | The Idris Community. |
Safe Haskell | None |
Language | Haskell98 |
- data Docstring a = DocString Options (Blocks a)
- data Block a
- data Inline a
- parseDocstring :: Text -> Docstring ()
- renderDocstring :: (a -> String -> Doc OutputAnnotation) -> Docstring a -> Doc OutputAnnotation
- emptyDocstring :: Docstring a
- nullDocstring :: Docstring a -> Bool
- noDocs :: (Docstring a, [(Name, Docstring a)])
- overview :: Docstring a -> Docstring a
- containsText :: Text -> Docstring a -> Bool
- renderHtml :: Docstring DocTerm -> Html
- annotCode :: forall a b. (String -> b) -> Docstring a -> Docstring b
- data DocTerm
- renderDocTerm :: (Term -> Doc OutputAnnotation) -> (Term -> Term) -> DocTerm -> String -> Doc OutputAnnotation
- checkDocstring :: forall a b. (String -> [String] -> String -> a -> b) -> Docstring a -> Docstring b
Documentation
Representation of Idris's inline documentation. The type paramter represents the type of terms that are associated with code blocks.
Block-level elements.
parseDocstring :: Text -> Docstring () Source #
Construct a docstring from a Text that contains Markdown-formatted docs
renderDocstring :: (a -> String -> Doc OutputAnnotation) -> Docstring a -> Doc OutputAnnotation Source #
Convert a docstring to be shown by the pretty-printer
emptyDocstring :: Docstring a Source #
The empty docstring
nullDocstring :: Docstring a -> Bool Source #
Check whether a docstring is emtpy
overview :: Docstring a -> Docstring a Source #
Construct a docstring consisting of the first block-level element of the argument docstring, for use in summaries.
Annotate the code samples in a docstring
The various kinds of code samples that can be embedded in docs
renderDocTerm :: (Term -> Doc OutputAnnotation) -> (Term -> Term) -> DocTerm -> String -> Doc OutputAnnotation Source #
Render a term in the documentation