forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#57508 - DebugSteven:inline-extern, r=Guilla…
…umeGomez rustdoc: Allow inlining of reexported crates and crate items Fixes rust-lang#46296 This PR checks for when a `pub extern crate` statement has a `#[doc(inline)]` attribute & inlines its contents. Code is based off of the inlining statements for `pub use` statements.
- Loading branch information
Showing
3 changed files
with
37 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#![crate_name = "inner"] | ||
pub struct SomeStruct; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// aux-build:pub-extern-crate.rs | ||
|
||
// @has pub_extern_crate/index.html | ||
// @!has - '//code' 'pub extern crate inner' | ||
// @has - '//a/@href' 'inner/index.html' | ||
// @has pub_extern_crate/inner/index.html | ||
// @has pub_extern_crate/inner/struct.SomeStruct.html | ||
#[doc(inline)] | ||
pub extern crate inner; |