Skip to content

Commit

Permalink
Enable pervasive to be built as a dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
hayley-leblanc committed Jul 26, 2023
1 parent 3ac9e37 commit cca8318
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
12 changes: 12 additions & 0 deletions source/pervasive/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[package]
name = "vstd"
version = "0.1.0"
edition = "2018"

[lib]
name = "vstd"
path = "vstd.rs"

[dependencies]
builtin_macros = { path = "../builtin_macros" }
builtin = { path = "../builtin" }
10 changes: 10 additions & 0 deletions source/pervasive/vstd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,16 @@

#![feature(core_intrinsics)]

#![cfg_attr(
not(verus_build),
feature(allocator_api),
feature(rustc_attrs),
feature(negative_impls),
feature(tuple_trait),
feature(unboxed_closures),
allow(unused)
)]

pub mod pervasive;
pub mod bytes;
pub mod calc_macro;
Expand Down
2 changes: 2 additions & 0 deletions source/vstd_build/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,8 @@ fn main() {
"--edition=2018".to_string(),
"--cfg".to_string(),
"erasure_macro_todo".to_string(),
"--cfg".to_string(),
"verus_build".to_string(),
"--crate-type=lib".to_string(),
"--out-dir".to_string(),
verus_target_path.to_str().expect("invalid path").to_string(),
Expand Down

0 comments on commit cca8318

Please sign in to comment.