mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-26 13:01:27 +03:00
11 lines
386 B
Rust
11 lines
386 B
Rust
//@ edition: 2024
|
|
#![no_std]
|
|
|
|
// Since the 2024 edition the link_section attribute must use the unsafe qualification.
|
|
// However, the unsafe qualification is not shown by rustdoc.
|
|
|
|
//@ count "$.index[?(@.name=='example')].attrs[*]" 1
|
|
//@ is "$.index[?(@.name=='example')].attrs[*].link_section" '"__TEXT,__text"'
|
|
#[unsafe(link_section = "__TEXT,__text")]
|
|
pub extern "C" fn example() {}
|