FStarLang / FStarLang/FStar

decreases clause does not support impure specs

Open
#4,337 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
F*
Stars
3.1k
Forks
267
Avg merge
10h 45m
Merged PRs (30d)
54

Description

```fstar
fn rec foo (x: ref nat)
preserves live x
decreases !x
{
if (!x > 0) {
x := (!x) - 1;
foo x;
}
}
```

Contributor guide

Open the contributing guide

Research direction

Use the F* reproducer in the issue as the starting case, focusing on how decreases clauses handle the impure expression `!x`. Reproduce the failure, locate the decreases-clause checking path, and confirm completion when this example is accepted or produces the intended verification result.

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
Quiet
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.