File: Mathlib/Tactic/HelpCmd.lean

full_name: Mathlib.Tactic.«command#help_Option___»
code: /--
The command `#help option` shows all options that have been defined in the current environment.
Each option has a format like:
```
option pp.all : Bool := false
  (pretty printer) display coercions, implicit parameters, proof terms, fully qualified names,
  universe, and disable beta reduction and notations during pretty printing
```
This says that `pp.all` is an option which can be set to a `Bool` value, and the default value is
`false`. If an option has been modified from the default using e.g. `set_option pp.all true`,
it will appear as a `(currently: true)` note next to the option.

The form `#help option id` will show only options that begin with `id`.
-/
syntax withPosition("#help " colGt &"option" (colGt ppSpace Parser.rawIdent)?) : command
goal: Lean.ParserDescr

full_name: _private.Mathlib.Tactic.HelpCmd.0.Mathlib.Tactic.elabHelpOption
code: private def elabHelpOption (id : Option Ident) : CommandElabM Unit 
goal: Lean.Elab.Command.CommandElabM Unit

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___elabRules_Mathlib_Tactic_command#help_Option____1»
code: elab_rules : command | `(#help option $(id)?) => elabHelpOption id
goal: Lean.Elab.Command.CommandElab

full_name: Mathlib.Tactic.«command#help_AttrAttribute___»
code: /--
The command `#help attribute` (or the short form `#help attr`) shows all attributes that have been
defined in the current environment.
Each option has a format like:
```
[inline]: mark definition to always be inlined
```
This says that `inline` is an attribute that can be placed on definitions like
`@[inline] def foo := 1`. (Individual attributes may have restrictions on where they can be
applied; see the attribute's documentation for details.) Both the attribute's `descr` field as well
as the docstring will be displayed here.

The form `#help attr id` will show only attributes that begin with `id`.
-/
syntax withPosition("#help " colGt (&"attr" <|> &"attribute")
    (colGt ppSpace Parser.rawIdent)?) : command
goal: Lean.ParserDescr

full_name: _private.Mathlib.Tactic.HelpCmd.0.Mathlib.Tactic.elabHelpAttr
code: private def elabHelpAttr (id : Option Ident) : CommandElabM Unit 
goal: Lean.Elab.Command.CommandElabM Unit

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___elabRules_Mathlib_Tactic_command#help_AttrAttribute____1»
code: elab_rules : command
  | `(#help attr $(id)?) => elabHelpAttr id
  | `(#help attribute $(id)?) => elabHelpAttr id
goal: Lean.Elab.Command.CommandElab

full_name: Mathlib.Tactic.getHeadTk
code: /-- Gets the initial string token in a parser description. For example, for a declaration like
`syntax "bla" "baz" term : tactic`, it returns `some "bla"`. Returns `none` for syntax declarations
that don't start with a string constant. -/
partial def getHeadTk (e : Expr) : Option String 
goal: Option String

full_name: Mathlib.Tactic.«command#help_Cats___»
code: /--
The command `#help cats` shows all syntax categories that have been defined in the
current environment.
Each syntax has a format like:
```
category command [Lean.Parser.initFn✝]
```
The name of the syntax category in this case is `command`, and `Lean.Parser.initFn✝` is the
name of the declaration that introduced it. (It is often an anonymous declaration like this,
but you can click to go to the definition.) It also shows the doc string if available.

The form `#help cats id` will show only syntax categories that begin with `id`.
-/
syntax withPosition("#help " colGt &"cats" (colGt ppSpace Parser.rawIdent)?) : command
goal: Lean.ParserDescr

full_name: _private.Mathlib.Tactic.HelpCmd.0.Mathlib.Tactic.elabHelpCats
code: private def elabHelpCats (id : Option Ident) : CommandElabM Unit 
goal: Lean.Elab.Command.CommandElabM Unit

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___elabRules_Mathlib_Tactic_command#help_Cats____1»
code: elab_rules : command | `(#help cats $(id)?) => elabHelpCats id
goal: Lean.Elab.Command.CommandElab

full_name: Mathlib.Tactic.«command#help_Cat+______»
code: /--
The command `#help cat C` shows all syntaxes that have been defined in syntax category `C` in the
current environment.
Each syntax has a format like:
```
syntax "first"... [Parser.tactic.first]
  `first | tac | ...` runs each `tac` until one succeeds, or else fails.
```
The quoted string is the leading token of the syntax, if applicable. It is followed by the full
name of the syntax (which you can also click to go to the definition), and the documentation.

* The form `#help cat C id` will show only attributes that begin with `id`.
* The form `#help cat+ C` will also show information about any `macro`s and `elab`s
  associated to the listed syntaxes.
-/
syntax withPosition("#help " colGt &"cat" "+"? colGt ident
    (colGt ppSpace (Parser.rawIdent <|> str))?) : command
goal: Lean.ParserDescr

full_name: _private.Mathlib.Tactic.HelpCmd.0.Mathlib.Tactic.elabHelpCat
code: private def elabHelpCat (more : Option Syntax) (catStx : Ident) (id : Option String) :
    CommandElabM Unit 
goal: Lean.Elab.Command.CommandElabM Unit

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___elabRules_Mathlib_Tactic_command#help_Cat+_______1»
code: elab_rules : command
  | `(#help cat $[+%$more]? $cat) => elabHelpCat more cat none
  | `(#help cat $[+%$more]? $cat $id:ident) => elabHelpCat more cat (id.getId.toString false)
  | `(#help cat $[+%$more]? $cat $id:str) => elabHelpCat more cat id.getString
goal: Lean.Elab.Command.CommandElab

full_name: Mathlib.Tactic.«command#help_Term+____»
code: /--
The command `#help term` shows all term syntaxes that have been defined in the current environment.
See `#help cat` for more information.
-/
syntax withPosition("#help " colGt &"term" "+"?
    (colGt ppSpace (Parser.rawIdent <|> str))?) : command
goal: Lean.ParserDescr

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___macroRules_Mathlib_Tactic_command#help_Term+_____1»
code: macro_rules
  | `(#help term%$tk $[+%$more]? $(id)?) =>
    `(#help cat$[+%$more]? $(mkIdentFrom tk `term) $(id)?)
goal: Lean.Macro

full_name: Mathlib.Tactic.«command#help_Tactic+____»
code: /--
The command `#help tactic` shows all tactics that have been defined in the current environment.
See `#help cat` for more information.
-/
syntax withPosition("#help " colGt &"tactic" "+"?
    (colGt ppSpace (Parser.rawIdent <|> str))?) : command
goal: Lean.ParserDescr

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___macroRules_Mathlib_Tactic_command#help_Tactic+_____1»
code: macro_rules
  | `(#help tactic%$tk $[+%$more]? $(id)?) =>
    `(#help cat$[+%$more]? $(mkIdentFrom tk `tactic) $(id)?)
goal: Lean.Macro

full_name: Mathlib.Tactic.«command#help_Conv+____»
code: /--
The command `#help conv` shows all tactics that have been defined in the current environment.
See `#help cat` for more information.
-/
syntax withPosition("#help " colGt &"conv" "+"?
    (colGt ppSpace (Parser.rawIdent <|> str))?) : command
goal: Lean.ParserDescr

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___macroRules_Mathlib_Tactic_command#help_Conv+_____1»
code: macro_rules
  | `(#help conv%$tk $[+%$more]? $(id)?) =>
    `(#help cat$[+%$more]? $(mkIdentFrom tk `conv) $(id)?)
goal: Lean.Macro

full_name: Mathlib.Tactic.«command#help_Command+____»
code: /--
The command `#help command` shows all commands that have been defined in the current environment.
See `#help cat` for more information.
-/
syntax withPosition("#help " colGt &"command" "+"?
    (colGt ppSpace (Parser.rawIdent <|> str))?) : command
goal: Lean.ParserDescr

full_name: Mathlib.Tactic.«_aux_Mathlib_Tactic_HelpCmd___macroRules_Mathlib_Tactic_command#help_Command+_____1»
code: macro_rules
  | `(#help command%$tk $[+%$more]? $(id)?) =>
    `(#help cat$[+%$more]? $(mkIdentFrom tk `command) $(id)?)
goal: Lean.Macro