Skip to content

Commit 8f9080d

Browse files
committed
Auto merge of #124847 - Oneirical:master, r=jieyouxu
Document tests in the `run-make` directory (A to C) Part of the #121876 project. This PR adds comments to some `run-make` tests which lack one, explaining _what_ is being tested. If possible, a link to the relevant PR or Issue responsible for the test is also provided. This will help the porting efforts to `rmake.rs`, and will also allow maintainers to focus efforts on tests which are more pertinent to port. For example, [this test](https://github.com/rust-lang/rust/blob/master/tests/run-make/cat-and-grep-sanity-check/Makefile) will become useless after all tests containing `CGREP` are successfully ported. In order to simplify review and at the suggestion of Kobzol on the rust-lang #gsoc Zulip, only the first 23 comments are part of this PR. If it is merged, future PRs will ensue commenting the rest of the tests. Could be an UI test: - `dep-info-doesnt-run-much`
2 parents e6e262f + bdab8b1 commit 8f9080d

File tree

23 files changed

+70
-0
lines changed

23 files changed

+70
-0
lines changed

tests/run-make/alloc-no-oom-handling/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that alloc can still compile correctly when the unstable no_global_oom_handling feature is turned on.
2+
# See https://github.com/rust-lang/rust/pull/84266
3+
14
include ../tools.mk
25

36
all:

tests/run-make/alloc-no-rc/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that alloc can still compile correctly when the unstable no_rc feature is turned on.
2+
# See https://github.com/rust-lang/rust/pull/89891
3+
14
include ../tools.mk
25

36
all:

tests/run-make/alloc-no-sync/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that alloc can still compile correctly when the unstable no_sync feature is turned on.
2+
# See https://github.com/rust-lang/rust/pull/89891
3+
14
include ../tools.mk
25

36
all:

tests/run-make/allocator-shim-circular-deps/Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# This test is designed to intentionally introduce a circular dependency scenario to check that a specific compiler bug doesn't make a resurgence.
2+
# The bug in question arose when at least one crate required a global allocator, and that crate was placed after the one defining it in the linker order.
3+
# The generated symbols.o should not result in any linker errors.
4+
# See https://github.com/rust-lang/rust/issues/112715
5+
16
# ignore-cross-compile
27
include ../tools.mk
38

tests/run-make/archive-duplicate-names/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# When two object archives with the same filename are present, an iterator is supposed to inspect each object, recognize the duplication and extract each one to a different directory.
2+
# This test checks that this duplicate handling behaviour has not been broken.
3+
# See https://github.com/rust-lang/rust/pull/24439
4+
15
# ignore-cross-compile
26
include ../tools.mk
37

tests/run-make/bare-outfile/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# This test checks that manually setting the output file as a bare file with no file extension still results in successful compilation.
2+
13
# ignore-cross-compile
24
include ../tools.mk
35

tests/run-make/c-dynamic-dylib/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that dynamic Rust linking with C does not encounter any errors, with dynamic dependencies given preference over static.
2+
# See https://github.com/rust-lang/rust/issues/10434
3+
14
# ignore-cross-compile
25
include ../tools.mk
36

tests/run-make/c-dynamic-rlib/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that dynamic Rust linking with C does not encounter any errors, with static dependencies given preference over dynamic. (This is the default behaviour.)
2+
# See https://github.com/rust-lang/rust/issues/10434
3+
14
# ignore-cross-compile
25
include ../tools.mk
36

tests/run-make/c-link-to-rust-dylib/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that C linking with Rust does not encounter any errors, with dynamic libraries.
2+
# See https://github.com/rust-lang/rust/issues/10434
3+
14
# ignore-cross-compile
25
include ../tools.mk
36

tests/run-make/c-link-to-rust-staticlib/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# This test checks that C linking with Rust does not encounter any errors, with static libraries.
2+
# See https://github.com/rust-lang/rust/issues/10434
3+
14
# ignore-cross-compile
25
include ../tools.mk
36

0 commit comments

Comments
 (0)