You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 14, 2023. It is now read-only.
Reduced the issue to a self-contained, reproducible test case.
Description
Using expr.pis on a very simple expression resulted in the following error (which I think means some of the intermediate representation for the parser are not removed).
1731:3: unknown declaration '2'
state:
x y : ℕ
⊢ false
Steps to Reproduce
Put the following in a Lean file:
open tactic
example {x y : ℕ}
: false :=
begin
(do x ← get_local `x,
p ← to_expr ```(x ≤ y),
type_check (p.pis [x]),
trace "success")
end
Expected behavior: [What you expect to happen]
"success" should get printed.
Actual behavior: [What actually happens]
Error:
1731:3: unknown declaration '2'
state:
x y : ℕ
⊢ false
Reproduces how often: [What percentage of the time does it reproduce?]
100%
Versions
You can get this information from copy and pasting the output of lean --version,
please include the OS and what version of the OS you're running.
This is not a bug but a feature request for a missing set of APIs that can work with these "special" local constants (called local_decl_refs in the C++ code) derived from a local context in contrast to "regular" locals constructed manually. For reference, here is a simple implementation of pis for this local kind:
namespace tactic
open expr
meta def pis : list expr → expr → tactic expr
| (l::ls) e :=
do local_const uniq pp info _ ← pure l,
t ← infer_type l,
e ← pis ls e,
pure $ pi pp info t (abstract_local e uniq)
| [] e := pure e
end tactic
Prerequisites
or feature requests.
Description
Using
expr.pis
on a very simple expression resulted in the following error (which I think means some of the intermediate representation for the parser are not removed).Steps to Reproduce
Put the following in a Lean file:
Expected behavior: [What you expect to happen]
"success"
should get printed.Actual behavior: [What actually happens]
Error:
Reproduces how often: [What percentage of the time does it reproduce?]
100%
Versions
You can get this information from copy and pasting the output of
lean --version
,please include the OS and what version of the OS you're running.
Mac OS X v 10.13.2
Additional Information
Any additional information, configuration or data that might be necessary to reproduce the issue.
The text was updated successfully, but these errors were encountered: