Skip to content

Update type annotations in the TLA+ spec of Tendermint for accountability#9263

Merged
konnov merged 5 commits intomainfrom
igor/spec-annotations1.2
Aug 16, 2022
Merged

Update type annotations in the TLA+ spec of Tendermint for accountability#9263
konnov merged 5 commits intomainfrom
igor/spec-annotations1.2

Conversation

@konnov
Copy link
Contributor

@konnov konnov commented Aug 16, 2022

This PR contains an update of type annotations for the TLA+ specification of Tendermint. By using the new type annotations, we make sure that no imprecise record access is possible. For details, see Type System 1.2 of Apalache.

Most of the diff is simple: Just using the new syntax for records and type aliases instead of the old syntax. Since the new type system of Apalache does not let one mix records of different shapes into a single set, we had to partition the state variable evidence into three variables: evidencePropose, evidencePrevote, evidencePrecommit. Alternatively, we could use variants, but that would only make the specification more complex.

@konnov konnov requested a review from josef-widder August 16, 2022 08:31
@konnov konnov marked this pull request as ready for review August 16, 2022 13:57
@konnov konnov requested a review from ebuchman as a code owner August 16, 2022 13:58
@konnov konnov requested review from a team August 16, 2022 13:58
Copy link
Contributor

@josef-widder josef-widder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

@konnov konnov merged commit 3003e05 into main Aug 16, 2022
@konnov konnov deleted the igor/spec-annotations1.2 branch August 16, 2022 14:12
cmwaters pushed a commit that referenced this pull request Aug 19, 2022
…lity (#9263)

* update Apalache type annotations and split evidence into 3 variables

* remove the duplicate of AllPrevotes, due to merge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants