https://github.com/argumentcomputer/RustFFI.lean
Template for Lean<->Rust FFI
https://github.com/argumentcomputer/RustFFI.lean
Last synced: 11 months ago
JSON representation
Template for Lean<->Rust FFI
- Host: GitHub
- URL: https://github.com/argumentcomputer/RustFFI.lean
- Owner: argumentcomputer
- License: mit
- Created: 2022-11-15T21:11:25.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-02-11T16:40:18.000Z (over 2 years ago)
- Last Synced: 2024-08-03T19:49:07.062Z (almost 2 years ago)
- Language: Lean
- Size: 14.6 KB
- Stars: 11
- Watchers: 3
- Forks: 1
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# RustFFI.lean
A template for calling Rust functions in Lean using Lean's C FFI.
Based on the [Lake FFI example](https://github.com/leanprover/lake/tree/master/examples/ffi) and [Rust's FFI docs](https://doc.rust-lang.org/nomicon/ffi.html#calling-rust-code-from-c).
## Running
Build/run `Main.lean` with `lake exe ffi`
It should print the result of `1 + 2`.
## Troubleshooting
Run `lake clean` and/or `cargo clean` after making changes.