- 
                Notifications
    
You must be signed in to change notification settings  - Fork 124
 
Description
cargo verus's implementation seems to pass along the parameters after the -- to all dependencies (including vstd), so something like cargo verus verify -- --verify-module bar for the following files will fail on the vstd build.
Cargo.toml
[package]
name = "foo"
version = "0.1.0"
edition = "2021"
[dependencies]
vstd = "=0.0.0-2025-08-12-1837"
[package.metadata.verus]
verify = truesrc/lib.rs
use vstd::prelude::*;
verus! {
mod bar {
    use vstd::prelude::*;
    fn baz() {
        assert(1 == 0 + 1);
    }
}
} // verus!The workaround for this is fairly straightforward, just run cargo verus verify first (so that vstd finishes; although you'll have to delete target/ first to clear out the cache), followed by cargo verus verify -- --verify-module bar, which then works as expected.
However, this workaround works fine only for single-crate situations.  If we are in a multi-crate workspace (e.g., https://github.com/verus-lang/verus-mode.el/tree/main/verus-examples/cv-workspace), then the there is no way to restrict the --verify-module to just a single one of the crates in the workspace.  Thus, we cannot benefit from partial verification which can be a performance bottleneck especially when working on a file (you can prob see why I hit this issue when adding support for cargo verus on workspaces within verus-mode.el).