Merge from rustc
This commit is contained in:
commit
daa250f912
421 changed files with 5539 additions and 3652 deletions
|
|
@ -1395,14 +1395,6 @@ impl<'test> TestCx<'test> {
|
|||
matches!(self.config.suite.as_str(), "rustdoc-ui" | "rustdoc-js" | "rustdoc-json")
|
||||
}
|
||||
|
||||
fn get_mir_dump_dir(&self) -> Utf8PathBuf {
|
||||
let mut mir_dump_dir = self.config.build_test_suite_root.clone();
|
||||
debug!("input_file: {}", self.testpaths.file);
|
||||
mir_dump_dir.push(&self.testpaths.relative_dir);
|
||||
mir_dump_dir.push(self.testpaths.file.file_stem().unwrap());
|
||||
mir_dump_dir
|
||||
}
|
||||
|
||||
fn make_compile_args(
|
||||
&self,
|
||||
input_file: &Utf8Path,
|
||||
|
|
@ -1511,10 +1503,7 @@ impl<'test> TestCx<'test> {
|
|||
}
|
||||
|
||||
let set_mir_dump_dir = |rustc: &mut Command| {
|
||||
let mir_dump_dir = self.get_mir_dump_dir();
|
||||
remove_and_create_dir_all(&mir_dump_dir).unwrap_or_else(|e| {
|
||||
panic!("failed to remove and recreate output directory `{mir_dump_dir}`: {e}")
|
||||
});
|
||||
let mir_dump_dir = self.output_base_dir();
|
||||
let mut dir_opt = "-Zdump-mir-dir=".to_string();
|
||||
dir_opt.push_str(mir_dump_dir.as_str());
|
||||
debug!("dir_opt: {:?}", dir_opt);
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ impl TestCx<'_> {
|
|||
self.diff_mir_files(from_file.into(), after.into())
|
||||
} else {
|
||||
let mut output_file = Utf8PathBuf::new();
|
||||
output_file.push(self.get_mir_dump_dir());
|
||||
output_file.push(self.output_base_dir());
|
||||
output_file.push(&from_file);
|
||||
debug!("comparing the contents of: {} with {:?}", output_file, expected_file);
|
||||
if !output_file.exists() {
|
||||
|
|
@ -100,7 +100,7 @@ impl TestCx<'_> {
|
|||
|
||||
fn diff_mir_files(&self, before: Utf8PathBuf, after: Utf8PathBuf) -> String {
|
||||
let to_full_path = |path: Utf8PathBuf| {
|
||||
let full = self.get_mir_dump_dir().join(&path);
|
||||
let full = self.output_base_dir().join(&path);
|
||||
if !full.exists() {
|
||||
panic!(
|
||||
"the mir dump file for {} does not exist (requested in {})",
|
||||
|
|
|
|||
|
|
@ -154,6 +154,7 @@ impl CommandKind {
|
|||
static LINE_PATTERN: LazyLock<Regex> = LazyLock::new(|| {
|
||||
RegexBuilder::new(
|
||||
r#"
|
||||
^\s*
|
||||
//@\s+
|
||||
(?P<negated>!?)
|
||||
(?P<cmd>[A-Za-z0-9]+(?:-[A-Za-z0-9]+)*)
|
||||
|
|
|
|||
|
|
@ -1382,6 +1382,11 @@ pub(crate) fn bool_to_simd_element(b: bool, size: Size) -> Scalar {
|
|||
}
|
||||
|
||||
pub(crate) fn simd_element_to_bool(elem: ImmTy<'_>) -> InterpResult<'_, bool> {
|
||||
assert!(
|
||||
matches!(elem.layout.ty.kind(), ty::Int(_) | ty::Uint(_)),
|
||||
"SIMD mask element type must be an integer, but this is `{}`",
|
||||
elem.layout.ty
|
||||
);
|
||||
let val = elem.to_scalar().to_int(elem.layout.size)?;
|
||||
interp_ok(match val {
|
||||
0 => false,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
thread $NAME panicked at tests/fail/panic/tls_macro_const_drop_panic.rs:LL:CC:
|
||||
ow
|
||||
fatal runtime error: thread local panicked on drop
|
||||
fatal runtime error: thread local panicked on drop, aborting
|
||||
error: abnormal termination: the program aborted execution
|
||||
|
||||
error: aborting due to 1 previous error
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
thread $NAME panicked at tests/fail/panic/tls_macro_drop_panic.rs:LL:CC:
|
||||
ow
|
||||
fatal runtime error: thread local panicked on drop
|
||||
fatal runtime error: thread local panicked on drop, aborting
|
||||
error: abnormal termination: the program aborted execution
|
||||
|
||||
error: aborting due to 1 previous error
|
||||
|
|
|
|||
|
|
@ -139,9 +139,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "bstr"
|
||||
version = "1.11.3"
|
||||
version = "1.12.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "531a9155a481e2ee699d4f98f43c0ca4ff8ee1bfd55c31e9e98fb29d2b176fe0"
|
||||
checksum = "234113d19d0d7d613b40e86fb654acf958910802bcceab913a4f9e7cda03b1a4"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
"regex-automata",
|
||||
|
|
@ -156,9 +156,9 @@ checksum = "1628fb46dfa0b37568d12e5edd512553eccf6a22a78e8bde00bb4aed84d5bdbf"
|
|||
|
||||
[[package]]
|
||||
name = "cc"
|
||||
version = "1.2.18"
|
||||
version = "1.2.19"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "525046617d8376e3db1deffb079e91cef90a89fc3ca5c185bbf8c9ecdd15cd5c"
|
||||
checksum = "8e3a13707ac958681c13b39b458c073d0d9bc8a22cb1b2f4c8e55eb72c13f362"
|
||||
dependencies = [
|
||||
"shlex",
|
||||
]
|
||||
|
|
@ -185,9 +185,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "clap"
|
||||
version = "4.5.35"
|
||||
version = "4.5.36"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d8aa86934b44c19c50f87cc2790e19f54f7a67aedb64101c2e1a2e5ecfb73944"
|
||||
checksum = "2df961d8c8a0d08aa9945718ccf584145eee3f3aa06cddbeac12933781102e04"
|
||||
dependencies = [
|
||||
"clap_builder",
|
||||
"clap_derive",
|
||||
|
|
@ -195,9 +195,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "clap_builder"
|
||||
version = "4.5.35"
|
||||
version = "4.5.36"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2414dbb2dd0695280da6ea9261e327479e9d37b0630f6b53ba2a11c60c679fd9"
|
||||
checksum = "132dbda40fb6753878316a489d5a1242a8ef2f0d9e47ba01c951ea8aa7d013a5"
|
||||
dependencies = [
|
||||
"anstream",
|
||||
"anstyle",
|
||||
|
|
@ -775,9 +775,9 @@ checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c"
|
|||
|
||||
[[package]]
|
||||
name = "jiff"
|
||||
version = "0.2.5"
|
||||
version = "0.2.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c102670231191d07d37a35af3eb77f1f0dbf7a71be51a962dcd57ea607be7260"
|
||||
checksum = "1f33145a5cbea837164362c7bd596106eb7c5198f97d1ba6f6ebb3223952e488"
|
||||
dependencies = [
|
||||
"jiff-static",
|
||||
"log",
|
||||
|
|
@ -788,9 +788,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "jiff-static"
|
||||
version = "0.2.5"
|
||||
version = "0.2.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4cdde31a9d349f1b1f51a0b3714a5940ac022976f4b49485fc04be052b183b4c"
|
||||
checksum = "43ce13c40ec6956157a3635d97a1ee2df323b263f09ea14165131289cb0f5c19"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
|
|
@ -840,9 +840,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "linux-raw-sys"
|
||||
version = "0.9.3"
|
||||
version = "0.9.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fe7db12097d22ec582439daf8618b8fdd1a7bef6270e9af3b1ebcd30893cf413"
|
||||
checksum = "cd945864f07fe9f5371a27ad7b52a172b4b499999f1d97574c9fa68373937e12"
|
||||
|
||||
[[package]]
|
||||
name = "litemap"
|
||||
|
|
@ -2022,9 +2022,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
|
|||
|
||||
[[package]]
|
||||
name = "winnow"
|
||||
version = "0.7.4"
|
||||
version = "0.7.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0e97b544156e9bebe1a0ffbc03484fc1ffe3100cbce3ffb17eac35f7cdd7ab36"
|
||||
checksum = "63d3fcd9bba44b03821e7d699eeee959f3126dcc4aa8e4ae18ec617c2a5cea10"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
]
|
||||
|
|
|
|||
|
|
@ -722,7 +722,7 @@ fn last_tok(tt: &TokenTree) -> Token {
|
|||
match *tt {
|
||||
TokenTree::Token(ref t, _) => t.clone(),
|
||||
TokenTree::Delimited(delim_span, _, delim, _) => Token {
|
||||
kind: TokenKind::CloseDelim(delim),
|
||||
kind: delim.as_open_token_kind(),
|
||||
span: delim_span.close,
|
||||
},
|
||||
}
|
||||
|
|
@ -1124,8 +1124,14 @@ fn next_space(tok: &TokenKind) -> SpaceState {
|
|||
TokenKind::PathSep
|
||||
| TokenKind::Pound
|
||||
| TokenKind::Dollar
|
||||
| TokenKind::OpenDelim(_)
|
||||
| TokenKind::CloseDelim(_) => SpaceState::Never,
|
||||
| TokenKind::OpenParen
|
||||
| TokenKind::CloseParen
|
||||
| TokenKind::OpenBrace
|
||||
| TokenKind::CloseBrace
|
||||
| TokenKind::OpenBracket
|
||||
| TokenKind::CloseBracket
|
||||
| TokenKind::OpenInvisible(_)
|
||||
| TokenKind::CloseInvisible(_) => SpaceState::Never,
|
||||
|
||||
TokenKind::Literal(..) | TokenKind::Ident(..) | TokenKind::Lifetime(..) => {
|
||||
SpaceState::Ident
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
use std::panic::{AssertUnwindSafe, catch_unwind};
|
||||
|
||||
use rustc_ast::ast;
|
||||
use rustc_ast::token::{Delimiter, TokenKind};
|
||||
use rustc_ast::token::TokenKind;
|
||||
use rustc_parse::exp;
|
||||
use rustc_parse::parser::ForceCollect;
|
||||
use rustc_span::symbol::kw;
|
||||
|
|
@ -60,9 +60,7 @@ fn parse_cfg_if_inner<'a>(
|
|||
return Err("Expected an opening brace");
|
||||
}
|
||||
|
||||
while parser.token != TokenKind::CloseDelim(Delimiter::Brace)
|
||||
&& parser.token.kind != TokenKind::Eof
|
||||
{
|
||||
while parser.token != TokenKind::CloseBrace && parser.token.kind != TokenKind::Eof {
|
||||
let item = match parser.parse_item(ForceCollect::No) {
|
||||
Ok(Some(item_ptr)) => item_ptr.into_inner(),
|
||||
Ok(None) => continue,
|
||||
|
|
|
|||
|
|
@ -1397,7 +1397,6 @@ ui/issues/auxiliary/issue-13620-1.rs
|
|||
ui/issues/auxiliary/issue-13620-2.rs
|
||||
ui/issues/auxiliary/issue-14344-1.rs
|
||||
ui/issues/auxiliary/issue-14344-2.rs
|
||||
ui/issues/auxiliary/issue-14421.rs
|
||||
ui/issues/auxiliary/issue-14422.rs
|
||||
ui/issues/auxiliary/issue-15562.rs
|
||||
ui/issues/auxiliary/issue-16643.rs
|
||||
|
|
@ -1564,7 +1563,6 @@ ui/issues/issue-14366.rs
|
|||
ui/issues/issue-14382.rs
|
||||
ui/issues/issue-14393.rs
|
||||
ui/issues/issue-14399.rs
|
||||
ui/issues/issue-14421.rs
|
||||
ui/issues/issue-14422.rs
|
||||
ui/issues/issue-14541.rs
|
||||
ui/issues/issue-14721.rs
|
||||
|
|
@ -1629,7 +1627,6 @@ ui/issues/issue-16774.rs
|
|||
ui/issues/issue-16783.rs
|
||||
ui/issues/issue-16819.rs
|
||||
ui/issues/issue-16922-rpass.rs
|
||||
ui/issues/issue-16939.rs
|
||||
ui/issues/issue-16966.rs
|
||||
ui/issues/issue-16994.rs
|
||||
ui/issues/issue-17001.rs
|
||||
|
|
@ -1867,7 +1864,6 @@ ui/issues/issue-23550.rs
|
|||
ui/issues/issue-23589.rs
|
||||
ui/issues/issue-23699.rs
|
||||
ui/issues/issue-2380-b.rs
|
||||
ui/issues/issue-23808.rs
|
||||
ui/issues/issue-2383.rs
|
||||
ui/issues/issue-23891.rs
|
||||
ui/issues/issue-23898.rs
|
||||
|
|
@ -2607,7 +2603,6 @@ ui/issues/issue-9249.rs
|
|||
ui/issues/issue-9259.rs
|
||||
ui/issues/issue-92741.rs
|
||||
ui/issues/issue-9446.rs
|
||||
ui/issues/issue-9719.rs
|
||||
ui/issues/issue-9725.rs
|
||||
ui/issues/issue-9737.rs
|
||||
ui/issues/issue-9814.rs
|
||||
|
|
@ -3138,7 +3133,6 @@ ui/nll/user-annotations/issue-55241.rs
|
|||
ui/nll/user-annotations/issue-55748-pat-types-constrain-bindings.rs
|
||||
ui/nll/user-annotations/issue-57731-ascibed-coupled-types.rs
|
||||
ui/numbers-arithmetic/issue-8460.rs
|
||||
ui/on-unimplemented/issue-104140.rs
|
||||
ui/or-patterns/issue-64879-trailing-before-guard.rs
|
||||
ui/or-patterns/issue-67514-irrefutable-param.rs
|
||||
ui/or-patterns/issue-68785-irrefutable-param-with-at.rs
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ use ignore::Walk;
|
|||
const ENTRY_LIMIT: u32 = 901;
|
||||
// FIXME: The following limits should be reduced eventually.
|
||||
|
||||
const ISSUES_ENTRY_LIMIT: u32 = 1631;
|
||||
const ISSUES_ENTRY_LIMIT: u32 = 1626;
|
||||
|
||||
const EXPECTED_TEST_FILE_EXTENSIONS: &[&str] = &[
|
||||
"rs", // test source files
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue