Documentation

Lean.Elab.DocString.Builtin.Parsing

def Lean.Doc.onlyCodes {m : Type → Type} [Monad m] [MonadError m] (xs : TSyntaxArray `Lean.Doc.Parser.inline) :

Requires that all non-whitespace arguments to a role are code elements, returning their content if so. Throws an error otherwise.

Instances For
    def Lean.Doc.onlyCode {m : Type → Type} [Monad m] [MonadError m] (xs : TSyntaxArray `Lean.Doc.Parser.inline) :

    Requires that the non-whitespace arguments to a role are a single code element, returning its content if so. Throws an error otherwise.

    Instances For
      def Lean.Doc.parseContent {m : Type → Type} [Monad m] [MonadFileMap m] [MonadEnv m] [MonadError m] [MonadLog m] [MonadOptions m] (p : Parser.ParserFn) (tok : Syntax) (contents : String) :
      Instances For
        Instances For
          Instances For

            Parses the contents of an inline code element.

            Instances For

              Parses the contents of a code block.

              Instances For

                Parses the contents of an inline code element, reporting errors rather than throwing.

                Instances For

                  Parses the contents of a string literal argument.

                  Instances For

                    Parses the contents of a string literal argument, reporting errors rather than throwing.

                    Instances For