Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sail-to-lean: annotate data type annotations (including quantifiers) #841

Open
tobiasgrosser opened this issue Dec 17, 2024 · 4 comments
Open
Assignees
Labels
Lean Issues with Sail to Lean translation

Comments

@tobiasgrosser
Copy link
Collaborator

tobiasgrosser commented Dec 17, 2024

Look over all files in https://github.com/rems-project/sail/tree/sail2/lib, e.g., https://github.com/rems-project/sail/blob/sail2/lib/flow.sail.

Here an example PR: https://github.com/rems-project/sail/pull/754/files

We may want to use HAdd.add instead of Int.add

@Alasdair Alasdair added the Lean Issues with Sail to Lean translation label Dec 17, 2024
@jprider63 jprider63 self-assigned this Jan 6, 2025
@jprider63
Copy link
Collaborator

@benjaminselfridge is actually working on this, but I don't seem to be able to assign it to him. @Alasdair would you please add him to the repository?

@jprider63
Copy link
Collaborator

From @javra:

New Lean defs go here: src/sail_lean_backend/Sail/Sail.lean

@benjaminselfridge
Copy link
Collaborator

We're starting a branch here: https://github.com/GaloisInc/sail/blob/feature/lean_external_arith/lib/arith.sail

Does the initial commit I made look sane to you?

@javra
Copy link
Collaborator

javra commented Jan 16, 2025

Looks good! There's a better abs in Mathlib, but since we don't want to depend on it, that's not an option.

You could also, in Sail.lean, add intAbs, define it as the composition you used, and thant refer to that in the annotation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Lean Issues with Sail to Lean translation
Projects
None yet
Development

No branches or pull requests

5 participants