Skip to content

Rust backend needs an option similar to --go-module-name or --python-module-name #5641

@robin-aws

Description

@robin-aws

In Rust the name of the crate containing code shows up in the namespace of consuming references. i.e. if a module foo.rs includes a definition bar and is packaged in a stuff crate, consuming code that depends on the stuff crate will have references like stuff::foo::bar. This means consuming Dafny code needs to be aware of how dependent code was built and packaged: the reference in Dafny code may be just foo.bar, but needs to be compiled to stuff::foo::bar.

The recently added translation record file format (*.dtr) is specifically made to track this information, by recording what relevant options were passed to dafny translate. We just need a analogous option for Rust to track the crate name.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions