Skip to content

configured-off modules are required to exist #5870

Closed
@doy

Description

@doy
// test.rs
#[cfg(foo)]
#[path = "foo.rs"]
pub mod backend;

#[cfg(not(foo))]
#[path = "bar.rs"]
pub mod backend;

If foo.rs does not exist, this fails to compile, even if bar.rs exists and the foo configuration option isn't given. Seems like only modules that are actually being compiled should be required to exist.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-attributesArea: Attributes (`#[…]`, `#![…]`)A-driverArea: rustc_driver that ties everything together into the `rustc` compilerA-frontendArea: Compiler frontend (errors, parsing and HIR)A-parserArea: The lexing & parsing of Rust source code to an ASTP-lowLow priority

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions