mirror of
https://github.com/rust-lang/rust.git
synced 2025-02-17 01:13:11 +00:00
Fix incremental compilation of cdylib emitting spurious unused_attributes lint
This commit is contained in:
parent
80e7cde223
commit
2adc6da7aa
@ -998,7 +998,7 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
|
||||
(sym::repr, Normal, template!(List: "C, packed, ..."), Ungated),
|
||||
(sym::path, Normal, template!(NameValueStr: "file"), Ungated),
|
||||
(sym::automatically_derived, Normal, template!(Word), Ungated),
|
||||
(sym::no_mangle, Normal, template!(Word), Ungated),
|
||||
(sym::no_mangle, Whitelisted, template!(Word), Ungated),
|
||||
(sym::no_link, Normal, template!(Word), Ungated),
|
||||
(sym::derive, Normal, template!(List: "Trait1, Trait2, ..."), Ungated),
|
||||
(
|
||||
|
10
src/test/incremental/no_mangle.rs
Normal file
10
src/test/incremental/no_mangle.rs
Normal file
@ -0,0 +1,10 @@
|
||||
// revisions:rpass1 rpass2
|
||||
// compile-flags: --crate-type cdylib
|
||||
// skip-codegen
|
||||
|
||||
#![deny(unused_attributes)]
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn rust_no_mangle() -> i32 {
|
||||
42
|
||||
}
|
Loading…
Reference in New Issue
Block a user