Skip to content
Open
Show file tree
Hide file tree
Changes from 15 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ Changes to the Lean backend:
- Use the explicit monadic phase to insert `pure` and `←` only on demand, and
not introduce extra `do` block (#1746)
- Rename `Result` monad to `RustM` to avoid confusion with Rust `Result` type (#1768)
- Add support for default methods of traits (#1777)
- Gather definitions in namespaces, shortening names (#1780)

Miscellaneous:
- Reserve extraction folder for auto-generated files in Lean examples (#1754)
Expand Down
7 changes: 7 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions engine/backends/lean/lean_backend.ml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ include
include On.Quote
include On.Dyn
include On.Unsafe
include On.Trait_item_default
end)
(struct
let backend = Diagnostics.Backend.FStar
Expand Down Expand Up @@ -45,7 +46,7 @@ module SubtypeToInputLanguage
and type state_passing_loop = Features.Off.state_passing_loop
and type fold_like_loop = Features.Off.fold_like_loop
and type match_guard = Features.Off.match_guard
and type trait_item_default = Features.Off.trait_item_default) =
and type trait_item_default = Features.On.trait_item_default) =
struct
module FB = InputLanguage

Expand Down Expand Up @@ -120,7 +121,6 @@ module TransformToInputLanguage =
|> Phases.Traits_specs
|> Phases.Simplify_hoisting
|> Phases.Newtype_as_refinement
|> Phases.Reject.Trait_item_default
|> Phases.Bundle_cycles
|> Phases.Reorder_fields
|> Phases.Sort_items
Expand Down
2 changes: 1 addition & 1 deletion examples/lean_chacha20/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ default:
lake build)

clean:
-rm -f proofs/lean/extraction/lean_chacha20.lean
-rm -f proofs/lean/extraction/
-cd proofs/lean && lake clean
1 change: 1 addition & 0 deletions rust-engine/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ pretty = "0.12"
derive_generic_visitor = "0.3.0"
pastey = "0.1.0"
camino = "1.1.11"
capitalize = "0.3.4"
Copy link
Member

Choose a reason for hiding this comment

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

Let's not bring an extra dependency for such a small utility function, just add it to as an helper somewhere (e.g. in a helper.rs file)

Loading
Loading