diff options
| author | 许杰友 Jieyou Xu (Joe) <39484203+jieyouxu@users.noreply.github.com> | 2025-02-28 22:29:52 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-02-28 22:29:52 +0800 |
| commit | 50ed7f974b167ddaed825db269698f3c134db474 (patch) | |
| tree | b2917bc06ba10da6ae3a069a09e5b79214564f6d /tests/codegen/function-return.rs | |
| parent | 50ef985be2680963c72c63c52fe33449aec58732 (diff) | |
| parent | 92eb4450fa1ae37a948178c9d14bfb145a69562d (diff) | |
| download | rust-50ed7f974b167ddaed825db269698f3c134db474.tar.gz rust-50ed7f974b167ddaed825db269698f3c134db474.zip | |
Rollup merge of #137599 - davidtwco:use-minicore-more, r=jieyouxu
tests: use minicore more minicore makes it much easier to add new language items to all of the existing `no_core` tests. Most of the remaining tests that *could* use minicore either fail because.. 1. LLVM IR output changes and doesn't pass the test as written. I didn't look into these further. 2. The test has revisions w/ different compilation flags, expecting some to fail, and when using minicore, minicore is compiled with those flags and fails in the expected way because of the flags rather than the test, and that's considered a failure. But these tests can be changed and make adding new language items a lot easier. r? ```@jieyouxu```
Diffstat (limited to 'tests/codegen/function-return.rs')
| -rw-r--r-- | tests/codegen/function-return.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/codegen/function-return.rs b/tests/codegen/function-return.rs index 2b9de4e1478..4127f516038 100644 --- a/tests/codegen/function-return.rs +++ b/tests/codegen/function-return.rs @@ -1,6 +1,7 @@ // Test that the `fn_ret_thunk_extern` function attribute is (not) emitted when // the `-Zfunction-return={keep,thunk-extern}` flag is (not) set. +//@ add-core-stubs //@ revisions: unset keep thunk-extern keep-thunk-extern thunk-extern-keep //@ needs-llvm-components: x86 //@ compile-flags: --target x86_64-unknown-linux-gnu @@ -13,8 +14,8 @@ #![feature(no_core, lang_items)] #![no_core] -#[lang = "sized"] -trait Sized {} +extern crate minicore; +use minicore::*; #[no_mangle] pub fn foo() { |
