Documentation

Lean.Elab.Open

A local copy of name resolution state that allows us to immediately use new open decls in further name resolution as in open Lean Elab.

Instances For
    @[reducible, inline]
    abbrev Lean.Elab.OpenDecl.M {m : Type → Type} (α : Type) :
    Equations
    Instances For
      @[instance_reducible]
      Equations
      • One or more equations did not get rendered due to their size.
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For

        Uniquely resolves the identifier idStx in the provided namespaces nss.

        If the identifier does not indicate a name in exactly one of the namespaces, an exception is thrown.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          def Lean.Elab.OpenDecl.elabOpenDecl {m : Type → Type} [Monad m] [MonadEnv m] [MonadExceptOf Exception m] [MonadRef m] [AddMessageContext m] [MonadLiftT (ST IO.RealWorld) m] [MonadLog m] [MonadOptions m] [MonadResolveName m] [MonadInfoTree m] (stx : TSyntax `Lean.Parser.Command.openDecl) (reportDeprecated : Syntax → Name → m Unit := fun (x : Syntax) (x_1 : Name) => pure ()) :

          Elaborates stx, returning the resulting open declarations. reportDeprecated is called on each identifier that is resolved relative to an opened namespace and on the declaration it refers to, see checkDeprecatedOpenedName.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For

            Reports declName if it is deprecated, where idStx refers to declName relative to an opened namespace. If the replacement is in that namespace, offers to replace idStx by the replacement relative to it.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              Equations
              • One or more equations did not get rendered due to their size.
              Instances For