| Copyright | (c) 2013-2025 Galois Inc. |
|---|---|
| License | BSD3 |
| Maintainer | cryptol@galois.com |
| Stability | provisional |
| Portability | portable |
| Safe Haskell | Safe |
| Language | Haskell2010 |
Cryptol.TypeCheck.Docstrings
Description
Documentation
extractCodeBlocks :: Text -> [[Text]] Source #
Extract the code blocks from the body of a docstring.
A single code block starts with at least 3 backticks followed by an optional language specifier of "cryptol". This allows other kinds of code blocks to be included (and ignored) in docstrings. Longer backtick sequences can be used when a code block needs to be able to contain backtick sequences.
/** * A docstring example * * ```cryptol * :check example * ``` */