Skip to content

build.rs strange behaviour with edition 2018 #5860

@matthiaskrgr

Description

@matthiaskrgr

rust-clippy used to build fine until

rustc 1.30.0-nightly (7e8ca9f8b 2018-08-03)
cargo 1.29.0-nightly (15433e8cc 2018-08-02)

It uses edition 2018 in Cargo.toml.

When building, it seems that some imports of build.rs are no longer found.
I was able to fix that by adding extern crate .... (see rust-lang/rust-clippy#3001 ) however clippy is rust 2018 and should not need that.
So is build.rs not edition 2018 if the rest of the project is?

I was also able to have

#![feature(rust_2018_preview)]
#![warn(rust_2018_idioms)]
extern crate ....

in build.rs without any warning, shouldn't it trigger some?

Clippy repo @ 8ef759e0273ad97f1acbb1ea9f94322aa2a20147

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