FStarLang / FStarLang/pulse

Computation readback does not recognize postconditions that are not lambdas

Open
#266 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
36
Forks
11
PR merge metrics
No merged PRs in 30d

Description

This snippet works, even if it seems to be introducing an `exists* (x:unit). Pure False`.

```pulse
fn
test_intro (_:unit)
requires emp
ensures emp
{
intro_exists (fun () -> pure False) ();
admit()
}
```

Removing the admit makes it fail as it should.

```pulse
fn
test_intro (_:unit)
requires emp
ensures emp
{
intro_exists (fun () -> pure False) ()
}
```

Puzzlingly, if I try to print the state before the admit, it seems as if `intro_exists` was not applied since it is bound at type `stt_ghost`.

```pulse
fn
test_intro (_:unit)
requires emp
ensures emp
{
intro_exists (fun () -> pure False) ();
show_proof_state;
admit()
}
```
```
- Tactic logged issue:
- Current context:
emp **
emp
- In typing environment:
[_#2 : stt_ghost unit emp_inames (pure l_False) (fun _ -> exists* (_: unit). pure l_False),
uu___85#1 : unit]
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the two Pulse test_intro snippets and inspecting computation readback for intro_exists postconditions that are not lambdas; compare the state shown by show_proof_state. Done means the version without admit is rejected as expected and the proof state reflects the applied intro_exists postcondition.

Written by the indexing model from the issue text.

Assessment

Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.