diff options
| author | bors <bors@rust-lang.org> | 2022-10-02 01:29:36 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-10-02 01:29:36 +0000 |
| commit | ab37a83ae2c829b8597bdcda8244964ebc60b495 (patch) | |
| tree | 3487ea9a22320968a90e80dce03d205f34a1d97f /src/test | |
| parent | b34cff1736b0b94686206f053c2c00c302240bb9 (diff) | |
| parent | c6d4421e965aa7a955c8f63c5bd97a47eb86f3aa (diff) | |
| download | rust-ab37a83ae2c829b8597bdcda8244964ebc60b495.tar.gz rust-ab37a83ae2c829b8597bdcda8244964ebc60b495.zip | |
Auto merge of #102558 - matthiaskrgr:rollup-0odec1c, r=matthiaskrgr
Rollup of 6 pull requests Successful merges: - #102195 (Improve the COPYRIGHT file) - #102313 (Update docs so that deprecated method points to relevant method) - #102353 (Allow passing rustix_use_libc cfg using RUSTFLAGS) - #102405 (Remove a FIXME whose code got moved away in #62883.) - #102525 (rustdoc: remove orphaned link on array bracket) - #102557 (fix issue with x.py setup running into explicit panic) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/rustdoc/array-links.link_box_generic.html | 1 | ||||
| -rw-r--r-- | src/test/rustdoc/array-links.link_box_u32.html | 1 | ||||
| -rw-r--r-- | src/test/rustdoc/array-links.link_slice_generic.html | 1 | ||||
| -rw-r--r-- | src/test/rustdoc/array-links.link_slice_u32.html | 1 | ||||
| -rw-r--r-- | src/test/rustdoc/array-links.rs | 28 |
5 files changed, 32 insertions, 0 deletions
diff --git a/src/test/rustdoc/array-links.link_box_generic.html b/src/test/rustdoc/array-links.link_box_generic.html new file mode 100644 index 00000000000..3481bb6a025 --- /dev/null +++ b/src/test/rustdoc/array-links.link_box_generic.html @@ -0,0 +1 @@ +<code>pub fn delta<T>() -> <a class="struct" href="struct.MyBox.html" title="struct foo::MyBox">MyBox</a><<a class="primitive" href="{{channel}}/core/primitive.array.html">[T; 1]</a>></code> \ No newline at end of file diff --git a/src/test/rustdoc/array-links.link_box_u32.html b/src/test/rustdoc/array-links.link_box_u32.html new file mode 100644 index 00000000000..e864ae55c9f --- /dev/null +++ b/src/test/rustdoc/array-links.link_box_u32.html @@ -0,0 +1 @@ +<code>pub fn gamma() -> <a class="struct" href="struct.MyBox.html" title="struct foo::MyBox">MyBox</a><[<a class="primitive" href="{{channel}}/core/primitive.u32.html">u32</a>; <a class="primitive" href="{{channel}}/core/primitive.array.html">1</a>]></code> \ No newline at end of file diff --git a/src/test/rustdoc/array-links.link_slice_generic.html b/src/test/rustdoc/array-links.link_slice_generic.html new file mode 100644 index 00000000000..f1ca2f59bd7 --- /dev/null +++ b/src/test/rustdoc/array-links.link_slice_generic.html @@ -0,0 +1 @@ +<code>pub fn beta<T>() -> &'static <a class="primitive" href="{{channel}}/core/primitive.array.html">[T; 1]</a></code> \ No newline at end of file diff --git a/src/test/rustdoc/array-links.link_slice_u32.html b/src/test/rustdoc/array-links.link_slice_u32.html new file mode 100644 index 00000000000..c3943e8d321 --- /dev/null +++ b/src/test/rustdoc/array-links.link_slice_u32.html @@ -0,0 +1 @@ +<code>pub fn alpha() -> &'static [<a class="primitive" href="{{channel}}/core/primitive.u32.html">u32</a>; <a class="primitive" href="{{channel}}/core/primitive.array.html">1</a>]</code> \ No newline at end of file diff --git a/src/test/rustdoc/array-links.rs b/src/test/rustdoc/array-links.rs new file mode 100644 index 00000000000..07f92ac51b9 --- /dev/null +++ b/src/test/rustdoc/array-links.rs @@ -0,0 +1,28 @@ +#![crate_name = "foo"] +#![no_std] + +pub struct MyBox<T: ?Sized>(*const T); + +// @has 'foo/fn.alpha.html' +// @snapshot link_slice_u32 - '//pre[@class="rust fn"]/code' +pub fn alpha() -> &'static [u32; 1] { + loop {} +} + +// @has 'foo/fn.beta.html' +// @snapshot link_slice_generic - '//pre[@class="rust fn"]/code' +pub fn beta<T>() -> &'static [T; 1] { + loop {} +} + +// @has 'foo/fn.gamma.html' +// @snapshot link_box_u32 - '//pre[@class="rust fn"]/code' +pub fn gamma() -> MyBox<[u32; 1]> { + loop {} +} + +// @has 'foo/fn.delta.html' +// @snapshot link_box_generic - '//pre[@class="rust fn"]/code' +pub fn delta<T>() -> MyBox<[T; 1]> { + loop {} +} |
