diff options
| author | Jubilee Young <workingjubilee@gmail.com> | 2025-06-24 21:21:13 -0700 |
|---|---|---|
| committer | Jubilee Young <workingjubilee@gmail.com> | 2025-06-25 00:54:02 -0700 |
| commit | 087dabfca7c39d68534bb8c23ffa78def4b24c37 (patch) | |
| tree | a42fd1a4141311fef92b926d24b5507d62832f7b | |
| parent | 78652b783dd1549d4782c2daba7d12214e001b54 (diff) | |
| download | rust-087dabfca7c39d68534bb8c23ffa78def4b24c37.tar.gz rust-087dabfca7c39d68534bb8c23ffa78def4b24c37.zip | |
Sprinkle breadcrumbs around to lead people to the rust-invalid ABI
| -rw-r--r-- | src/doc/rustc-dev-guide/src/tests/ui.md | 5 | ||||
| -rw-r--r-- | tests/ui/SUMMARY.md | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/doc/rustc-dev-guide/src/tests/ui.md b/src/doc/rustc-dev-guide/src/tests/ui.md index 8f4467a5551..09dc476d68e 100644 --- a/src/doc/rustc-dev-guide/src/tests/ui.md +++ b/src/doc/rustc-dev-guide/src/tests/ui.md @@ -59,6 +59,11 @@ The output is normalized to ignore unwanted differences, see the [Normalization](#normalization) section. If the file is missing, then compiletest expects the corresponding output to be empty. +A common reason to use normalization, revisions, and most of the other following tools, +is to account for platform differences. Consider alternatives to these tools, like +e.g. using the `extern "rust-invalid"` ABI that is invalid on every platform +instead of fixing the test to use cross-compilation and testing every possibly-invalid ABI. + There can be multiple stdout/stderr files. The general form is: ```text diff --git a/tests/ui/SUMMARY.md b/tests/ui/SUMMARY.md index d807e38dab2..e44959e3564 100644 --- a/tests/ui/SUMMARY.md +++ b/tests/ui/SUMMARY.md @@ -8,6 +8,8 @@ For now, only immediate subdirectories under `tests/ui/` are described, but thes These tests deal with *Application Binary Interfaces* (ABI), mostly relating to function name mangling (and the `#[no_mangle]` attribute), calling conventions, or compiler flags which affect ABI. +Tests for unsupported ABIs can be made cross-platform by using the `extern "rust-invalid"` ABI, which is considered unsupported on every platform. + ## `tests/ui/allocator` These tests exercise `#![feature(allocator_api)]` and the `#[global_allocator]` attribute. |
