Skip to content

Commit 5a12e86

Browse files
authored
Unrolled build for rust-lang#125382
Rollup merge of rust-lang#125382 - notriddle:notriddle/issue-d, r=fmease rustdoc: rename `issue-\d+.rs` tests to have meaningful names (part 7) Follow up * rust-lang#116214 * rust-lang#116432 * rust-lang#116824 * rust-lang#118105 * rust-lang#119561 * rust-lang#123574 As always, it's easier to review the commits one at a time. Don't use the Files Changed tab. It's confusing.
2 parents 93e7cb8 + b5923a9 commit 5a12e86

26 files changed

+80
-51
lines changed

Diff for: tests/rustdoc/issue-95633.rs renamed to tests/rustdoc-ui/pub-use-primitive-document-private-items-95633.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1+
//@ check-pass
12
//@ compile-flags: --document-private-items
23

34
// This ensures that no ICE is triggered when rustdoc is run on this code.
5+
// https://github.com./rust-lang/rust/issues/95633
46

57
mod stdlib {
68
pub (crate) use std::i8;

Diff for: tests/rustdoc/issue-82465-asref-for-and-of-local.rs renamed to tests/rustdoc/asref-for-and-of-local-82465.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
1+
// https://github.com./rust-lang/rust/issues/82465
2+
#![crate_name = "foo"]
3+
14
use std::convert::AsRef;
25
pub struct Local;
36

4-
// @has issue_82465_asref_for_and_of_local/struct.Local.html '//h3[@class="code-header"]' 'impl AsRef<str> for Local'
7+
// @has foo/struct.Local.html '//h3[@class="code-header"]' 'impl AsRef<str> for Local'
58
impl AsRef<str> for Local {
69
fn as_ref(&self) -> &str {
710
todo!()

Diff for: tests/rustdoc/issue-88600.rs renamed to tests/rustdoc/enum-variant-doc-hidden-field-88600.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
// This test ensure that #[doc(hidden)] is applied correctly in enum variant fields.
2+
// https://github.com./rust-lang/rust/issues/88600
3+
#![crate_name = "foo"]
24

35
// Denotes a field which should be hidden.
46
pub struct H;
57

68
// Denotes a field which should not be hidden (shown).
79
pub struct S;
810

9-
// @has issue_88600/enum.FooEnum.html
11+
// @has foo/enum.FooEnum.html
1012
pub enum FooEnum {
1113
// @has - '//*[@id="variant.HiddenTupleItem"]//h3' 'HiddenTupleItem(/* private fields */)'
1214
// @count - '//*[@id="variant.HiddenTupleItem.field.0"]' 0

Diff for: tests/rustdoc/issue-89309-heading-levels.rs renamed to tests/rustdoc/heading-levels-89309.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com./rust-lang/rust/issues/89309
12
#![crate_name = "foo"]
23

34
// @has foo/trait.Read.html

Diff for: tests/rustdoc/issue-85454.rs renamed to tests/rustdoc/inline_cross/qpath-self-85454.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
//@ aux-build:issue-85454.rs
22
//@ build-aux-docs
33
#![crate_name = "foo"]
4+
// https://github.com./rust-lang/rust/issues/85454
45

56
extern crate issue_85454;
67

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
//@ aux-build:reexport-with-anonymous-lifetime-98697.rs
2+
//@ ignore-cross-compile
3+
#![crate_name = "foo"]
4+
5+
// When reexporting a function with a HRTB with anonymous lifetimes,
6+
// make sure the anonymous lifetimes are not rendered.
7+
//
8+
// https://github.com./rust-lang/rust/issues/98697
9+
10+
extern crate reexport_with_anonymous_lifetime_98697;
11+
12+
// @has foo/fn.repro.html '//pre[@class="rust item-decl"]/code' 'fn repro<F>()where F: Fn(&str)'
13+
// @!has foo/fn.repro.html '//pre[@class="rust item-decl"]/code' 'for<'
14+
pub use reexport_with_anonymous_lifetime_98697::repro;
15+
16+
// @has foo/struct.Extra.html '//div[@id="trait-implementations-list"]//h3[@class="code-header"]' 'impl MyTrait<&Extra> for Extra'
17+
// @!has foo/struct.Extra.html '//div[@id="trait-implementations-list"]//h3[@class="code-header"]' 'impl<'
18+
pub use reexport_with_anonymous_lifetime_98697::Extra;

Diff for: tests/rustdoc/issue-94183-blanket-impl-reexported-trait.rs renamed to tests/rustdoc/inline_local/blanket-impl-reexported-trait-94183.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// This test ensures that a publicly re-exported private trait will
33
// appear in the blanket impl list.
44

5+
// https://github.com./rust-lang/rust/issues/94183
56
#![crate_name = "foo"]
67

78
// @has 'foo/struct.S.html'

Diff for: tests/rustdoc/issue-81141-private-reexport-in-public-api-2.rs renamed to tests/rustdoc/inline_local/private-reexport-in-public-api-81141-2.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ edition:2015
22

3+
// https://github.com./rust-lang/rust/issues/81141
34
#![crate_name = "foo"]
45

56
use external::Public as Private;

Diff for: tests/rustdoc/issue-81141-private-reexport-in-public-api.rs renamed to tests/rustdoc/inline_local/private-reexport-in-public-api-81141.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// This test ensures that if a private re-export is present in a public API, it'll be
22
// replaced by the first public item in the re-export chain or by the private item.
33

4+
// https://github.com./rust-lang/rust/issues/81141
45
#![crate_name = "foo"]
56

67
use crate::bar::Bar as Alias;

Diff for: tests/rustdoc/issue-81141-private-reexport-in-public-api-generics.rs renamed to tests/rustdoc/inline_local/private-reexport-in-public-api-generics-81141.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com./rust-lang/rust/issues/81141
12
#![crate_name = "foo"]
23

34
use crate::bar::Foo as Alias;

Diff for: tests/rustdoc/issue-81141-private-reexport-in-public-api-hidden.rs renamed to tests/rustdoc/inline_local/private-reexport-in-public-api-hidden-81141.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ compile-flags: -Z unstable-options --document-hidden-items
22

3+
// https://github.com./rust-lang/rust/issues/81141
34
#![crate_name = "foo"]
45

56
#[doc(hidden)]

Diff for: tests/rustdoc/issue-81141-private-reexport-in-public-api-private.rs renamed to tests/rustdoc/inline_local/private-reexport-in-public-api-private-81141.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ compile-flags: --document-private-items
22

3+
// https://github.com./rust-lang/rust/issues/81141
34
#![crate_name = "foo"]
45

56
use crate::bar::Bar as Alias;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
//@ edition:2018
2+
3+
// https://github.com./rust-lang/rust/issues/89852
4+
#![crate_name = "foo"]
5+
#![no_core]
6+
#![feature(no_core)]
7+
8+
// @matchesraw 'foo/sidebar-items.js' '"repro"'
9+
// @!matchesraw 'foo/sidebar-items.js' '"repro".*"repro"'
10+
11+
#[macro_export]
12+
macro_rules! repro {
13+
() => {};
14+
}
15+
16+
pub use crate::repro as repro2;

Diff for: tests/rustdoc/issue-86620.rs

-9
This file was deleted.

Diff for: tests/rustdoc/issue-89852.rs

-14
This file was deleted.

Diff for: tests/rustdoc/issue-95873.rs

-2
This file was deleted.

Diff for: tests/rustdoc/issue-98697.rs

-17
This file was deleted.

Diff for: tests/rustdoc/method-anchor-in-blanket-impl-86620.rs

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
//@ aux-build:issue-86620-1.rs
2+
#![crate_name = "foo"]
3+
// https://github.com./rust-lang/rust/issues/86620
4+
5+
extern crate issue_86620_1;
6+
7+
use issue_86620_1::*;
8+
9+
// @!has foo/struct.S.html '//*[@id="method.vzip"]//a[@class="fnname"]/@href' #tymethod.vzip
10+
// @has foo/struct.S.html '//*[@id="method.vzip"]//a[@class="anchor"]/@href' #method.vzip
11+
pub struct S;

Diff for: tests/rustdoc/issue-99221-multiple-macro-rules-w-same-name-submodule.rs renamed to tests/rustdoc/multiple-macro-rules-w-same-name-submodule-99221.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
//@ build-aux-docs
33
//@ ignore-cross-compile
44

5+
// https://github.com./rust-lang/rust/issues/99221
56
#![crate_name = "foo"]
67

78
#[macro_use]
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com./rust-lang/rust/issues/83375
12
#![crate_name = "foo"]
23

34
pub mod sub {
@@ -8,9 +9,9 @@ pub mod sub {
89
}
910
}
1011

11-
#[doc(inline)]
12-
pub use sub::*;
13-
1412
// @count foo/index.html '//a[@class="mod"][@title="mod foo::prelude"]' 1
1513
// @count foo/prelude/index.html '//div[@class="item-row"]' 0
1614
pub mod prelude {}
15+
16+
#[doc(inline)]
17+
pub use sub::*;

Diff for: tests/rustdoc/issue-83375-multiple-mods-w-same-name-doc-inline.rs renamed to tests/rustdoc/multiple-mods-w-same-name-doc-inline-last-item-83375.rs

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com./rust-lang/rust/issues/83375
12
#![crate_name = "foo"]
23

34
pub mod sub {
@@ -8,9 +9,9 @@ pub mod sub {
89
}
910
}
1011

12+
#[doc(inline)]
13+
pub use sub::*;
14+
1115
// @count foo/index.html '//a[@class="mod"][@title="mod foo::prelude"]' 1
1216
// @count foo/prelude/index.html '//div[@class="item-row"]' 0
1317
pub mod prelude {}
14-
15-
#[doc(inline)]
16-
pub use sub::*;

Diff for: tests/rustdoc/pub-use-root-path-95873.rs

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// https://github.com./rust-lang/rust/issues/95873
2+
#![crate_name = "foo"]
3+
4+
// @has foo/index.html "//*[@class='item-name']" "pub use ::std as x;"
5+
pub use ::std as x;

Diff for: tests/rustdoc/issue-80233-normalize-auto-trait.rs renamed to tests/rustdoc/synthetic_auto/normalize-auto-trait-80233.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
// Regression test for issue #80233
22
// Tests that we don't ICE when processing auto traits
3+
// https://github.com./rust-lang/rust/issues/80233
34

45
#![crate_type = "lib"]
6+
#![crate_name = "foo"]
57
pub trait Trait1 {}
68

79
pub trait Trait2 {
@@ -30,7 +32,7 @@ impl<T: Trait3> Trait3 for Vec<T> {
3032

3133
pub struct Struct1 {}
3234

33-
// @has issue_80233_normalize_auto_trait/struct.Question.html
35+
// @has foo/struct.Question.html
3436
// @has - '//h3[@class="code-header"]' 'impl<T> Send for Question<T>'
3537
pub struct Question<T: Trait1> {
3638
pub ins: <<Vec<T> as Trait3>::Type3 as Trait2>::Type2,

Diff for: tests/rustdoc/issue-96381.rs renamed to tests/rustdoc/underscore-type-in-trait-impl-96381.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
//@ should-fail
2+
// https://github.com./rust-lang/rust/issues/96381
23

34
#![allow(unused)]
45

0 commit comments

Comments
 (0)