Skip to content

Commit e785093

Browse files
authored
Merge pull request #450 from rust-lang/sync_from_rust_2024_02_20
Sync from rust 2024/02/20
2 parents 3e02db2 + e7b7c98 commit e785093

28 files changed

+166
-190
lines changed

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build_system/src/prepare.rs

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -159,21 +159,6 @@ where
159159
let repo_path = Path::new(crate::BUILD_DIR).join(&clone_result.repo_name);
160160
run_command(&[&"git", &"checkout", &"--", &"."], Some(&repo_path))?;
161161
run_command(&[&"git", &"checkout", &checkout_commit], Some(&repo_path))?;
162-
let filter = format!("-{}-", clone_result.repo_name);
163-
walk_dir(
164-
"patches/crate_patches",
165-
|_| Ok(()),
166-
|file_path| {
167-
let patch = file_path.as_os_str().to_str().unwrap();
168-
if patch.contains(&filter) && patch.ends_with(".patch") {
169-
run_command_with_output(
170-
&[&"git", &"am", &file_path.canonicalize().unwrap()],
171-
Some(&repo_path),
172-
)?;
173-
}
174-
Ok(())
175-
},
176-
)?;
177162
if let Some(extra) = extra {
178163
extra(&repo_path)?;
179164
}
@@ -238,7 +223,7 @@ pub fn run() -> Result<(), String> {
238223
let to_clone = &[
239224
(
240225
"https://github.com/rust-random/rand.git",
241-
"0f933f9c7176e53b2a3c7952ded484e1783f0bf1",
226+
"1f4507a8e1cf8050e4ceef95eeda8f64645b6719",
242227
None,
243228
),
244229
(

example/mini_core.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
thread_local
55
)]
66
#![no_core]
7-
#![allow(dead_code, internal_features)]
7+
#![allow(dead_code, internal_features, ambiguous_wide_pointer_comparisons)]
88

99
#[no_mangle]
1010
unsafe extern "C" fn _Unwind_Resume() {
@@ -100,9 +100,6 @@ unsafe impl<T: ?Sized> Freeze for &mut T {}
100100
#[lang = "structural_peq"]
101101
pub trait StructuralPartialEq {}
102102

103-
#[lang = "structural_teq"]
104-
pub trait StructuralEq {}
105-
106103
#[lang = "not"]
107104
pub trait Not {
108105
type Output;

example/mini_core_hello_world.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,9 @@ fn start<T: Termination + 'static>(
9898
}
9999

100100
static mut NUM: u8 = 6 * 7;
101+
102+
// FIXME: Use `SyncUnsafeCell` instead of allowing `static_mut_refs` lint
103+
#[allow(static_mut_refs)]
101104
static NUM_REF: &'static u8 = unsafe { &NUM };
102105

103106
macro_rules! assert {

example/std_example.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#![allow(internal_features)]
12
#![feature(core_intrinsics, coroutines, coroutine_trait, is_sorted)]
23

34
#[cfg(feature="master")]

patches/0022-core-Disable-not-compiling-tests.patch

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,4 @@ index 42a26ae..5ac1042 100644
3939
+#![cfg(test)]
4040
#![feature(alloc_layout_extra)]
4141
#![feature(array_chunks)]
42-
#![feature(array_methods)]
43-
--
44-
2.21.0 (Apple Git-122)
42+
#![feature(array_windows)]

patches/crate_patches/0002-rand-Disable-failing-test.patch

Lines changed: 0 additions & 32 deletions
This file was deleted.

patches/cross_patches/0001-Disable-libstd-and-libtest-dylib.patch

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,3 @@ index 5b21355..cb0c49b 100644
2121

2222
[dependencies]
2323
alloc = { path = "../alloc", public = true }
24-
diff --git a/library/test/Cargo.toml b/library/test/Cargo.toml
25-
index 91a1abd..a58c160 100644
26-
--- a/library/test/Cargo.toml
27-
+++ b/library/test/Cargo.toml
28-
@@ -4,7 +4,7 @@ version = "0.0.0"
29-
edition = "2021"
30-
31-
[lib]
32-
-crate-type = ["dylib", "rlib"]
33-
+crate-type = ["rlib"]
34-
35-
[dependencies]
36-
getopts = { version = "0.2.21", features = ['rustc-dep-of-std'] }
37-
--
38-
2.42.0
39-

rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[toolchain]
2-
channel = "nightly-2023-11-17"
2+
channel = "nightly-2024-02-20"
33
components = ["rust-src", "rustc-dev", "llvm-tools-preview"]

src/allocator.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ fn create_wrapper_function(
9090
.collect();
9191
let func = context.new_function(None, FunctionType::Exported, output.unwrap_or(void), &args, from_name, false);
9292

93-
if tcx.sess.target.options.default_hidden_visibility {
93+
if tcx.sess.default_hidden_visibility() {
9494
#[cfg(feature="master")]
9595
func.add_attribute(FnAttribute::Visibility(gccjit::Visibility::Hidden));
9696
}

0 commit comments

Comments
 (0)