Skip to content

Commit

Permalink
Auto merge of rust-lang#3252 - rust-lang:rustup-2024-01-05, r=RalfJung
Browse files Browse the repository at this point in the history
Automatic Rustup
  • Loading branch information
bors committed Jan 5, 2024
2 parents 38847ae + d11a2bd commit 39c714b
Show file tree
Hide file tree
Showing 1,256 changed files with 18,848 additions and 10,855 deletions.
20 changes: 4 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -361,8 +361,8 @@ jobs:
os: macos-13
- name: dist-aarch64-apple
env:
SCRIPT: "./x.py dist bootstrap --include-default-paths --host=aarch64-apple-darwin --target=aarch64-apple-darwin"
RUST_CONFIGURE_ARGS: "--enable-full-tools --enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false --set rust.lto=thin"
SCRIPT: "./x.py dist bootstrap --include-default-paths --stage 2"
RUST_CONFIGURE_ARGS: "--build=x86_64-apple-darwin --host=aarch64-apple-darwin --target=aarch64-apple-darwin --enable-full-tools --enable-sanitizers --enable-profiler --disable-docs --set rust.jemalloc --set llvm.ninja=false"
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
SELECT_XCODE: /Applications/Xcode_13.4.1.app
USE_XCODE_CLANG: 1
Expand All @@ -372,20 +372,8 @@ jobs:
NO_DEBUG_ASSERTIONS: 1
NO_OVERFLOW_CHECKS: 1
DIST_REQUIRE_ALL_TOOLS: 1
os: macos-13-xlarge
- name: aarch64-apple
env:
SCRIPT: "./x.py --stage 2 test --host=aarch64-apple-darwin --target=aarch64-apple-darwin"
RUST_CONFIGURE_ARGS: "--enable-sanitizers --enable-profiler --set rust.jemalloc --set llvm.ninja=false"
RUSTC_RETRY_LINKER_ON_SEGFAULT: 1
SELECT_XCODE: /Applications/Xcode_13.4.1.app
USE_XCODE_CLANG: 1
MACOSX_DEPLOYMENT_TARGET: 11.0
MACOSX_STD_DEPLOYMENT_TARGET: 11.0
NO_LLVM_ASSERTIONS: 1
NO_DEBUG_ASSERTIONS: 1
NO_OVERFLOW_CHECKS: 1
os: macos-13-xlarge
JEMALLOC_SYS_WITH_LG_PAGE: 14
os: macos-13
- name: x86_64-msvc
env:
RUST_CONFIGURE_ARGS: "--build=x86_64-pc-windows-msvc --enable-profiler"
Expand Down
47 changes: 24 additions & 23 deletions Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -285,9 +285,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"

[[package]]
name = "bitflags"
version = "2.4.0"
version = "2.4.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635"
checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07"

[[package]]
name = "block-buffer"
Expand Down Expand Up @@ -537,7 +537,7 @@ checksum = "2da6da31387c7e4ef160ffab6d5e7f00c42626fe39aea70a7b0f1773f7dd6c1b"

[[package]]
name = "clippy"
version = "0.1.76"
version = "0.1.77"
dependencies = [
"anstream",
"clippy_config",
Expand Down Expand Up @@ -565,7 +565,7 @@ dependencies = [

[[package]]
name = "clippy_config"
version = "0.1.76"
version = "0.1.77"
dependencies = [
"rustc-semver",
"serde",
Expand All @@ -588,7 +588,7 @@ dependencies = [

[[package]]
name = "clippy_lints"
version = "0.1.76"
version = "0.1.77"
dependencies = [
"arrayvec",
"cargo_metadata 0.15.4",
Expand All @@ -613,7 +613,7 @@ dependencies = [

[[package]]
name = "clippy_utils"
version = "0.1.76"
version = "0.1.77"
dependencies = [
"arrayvec",
"clippy_config",
Expand Down Expand Up @@ -984,7 +984,7 @@ checksum = "a0afaad2b26fa326569eb264b1363e8ae3357618c43982b3f285f0774ce76b69"

[[package]]
name = "declare_clippy_lint"
version = "0.1.76"
version = "0.1.77"
dependencies = [
"itertools",
"quote",
Expand Down Expand Up @@ -3370,7 +3370,7 @@ dependencies = [
name = "rustc_abi"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"rand",
"rand_xoshiro",
"rustc_data_structures",
Expand Down Expand Up @@ -3401,7 +3401,7 @@ dependencies = [
name = "rustc_ast"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"memchr",
"rustc_data_structures",
"rustc_index",
Expand Down Expand Up @@ -3552,7 +3552,7 @@ dependencies = [
name = "rustc_codegen_llvm"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"itertools",
"libc",
"measureme",
Expand Down Expand Up @@ -3587,7 +3587,7 @@ name = "rustc_codegen_ssa"
version = "0.0.0"
dependencies = [
"ar_archive_writer",
"bitflags 1.3.2",
"bitflags 2.4.1",
"cc",
"itertools",
"jobserver",
Expand Down Expand Up @@ -3654,7 +3654,7 @@ name = "rustc_data_structures"
version = "0.0.0"
dependencies = [
"arrayvec",
"bitflags 1.3.2",
"bitflags 2.4.1",
"elsa",
"ena",
"indexmap",
Expand Down Expand Up @@ -4121,7 +4121,7 @@ dependencies = [
name = "rustc_metadata"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"libloading 0.7.4",
"odht",
"rustc_ast",
Expand Down Expand Up @@ -4151,7 +4151,7 @@ dependencies = [
name = "rustc_middle"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"derive_more",
"either",
"field-offset",
Expand Down Expand Up @@ -4286,7 +4286,7 @@ dependencies = [
name = "rustc_parse"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"rustc_ast",
"rustc_ast_pretty",
"rustc_data_structures",
Expand Down Expand Up @@ -4424,7 +4424,7 @@ dependencies = [
name = "rustc_resolve"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"pulldown-cmark",
"rustc_arena",
"rustc_ast",
Expand Down Expand Up @@ -4463,7 +4463,7 @@ dependencies = [
name = "rustc_session"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"getopts",
"libc",
"rustc_ast",
Expand Down Expand Up @@ -4521,7 +4521,7 @@ dependencies = [
name = "rustc_symbol_mangling"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"punycode",
"rustc-demangle",
"rustc_data_structures",
Expand All @@ -4539,7 +4539,7 @@ dependencies = [
name = "rustc_target"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"object",
"rustc_abi",
"rustc_data_structures",
Expand All @@ -4563,6 +4563,7 @@ checksum = "8ba09476327c4b70ccefb6180f046ef588c26a24cf5d269a9feba316eb4f029f"
name = "rustc_trait_selection"
version = "0.0.0"
dependencies = [
"itertools",
"rustc_ast",
"rustc_attr",
"rustc_data_structures",
Expand Down Expand Up @@ -4637,7 +4638,7 @@ dependencies = [
name = "rustc_type_ir"
version = "0.0.0"
dependencies = [
"bitflags 1.3.2",
"bitflags 2.4.1",
"derivative",
"rustc_data_structures",
"rustc_index",
Expand Down Expand Up @@ -4767,7 +4768,7 @@ version = "0.38.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "745ecfa778e66b2b63c88a61cb36e0eea109e803b0b86bf9879fbc77c70e86ed"
dependencies = [
"bitflags 2.4.0",
"bitflags 2.4.1",
"errno",
"libc",
"linux-raw-sys",
Expand Down Expand Up @@ -5205,9 +5206,9 @@ dependencies = [

[[package]]
name = "sysinfo"
version = "0.29.2"
version = "0.29.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9557d0845b86eea8182f7b10dff120214fb6cd9fd937b6f4917714e546a38695"
checksum = "cd727fc423c2060f6c92d9534cef765c65a6ed3f428a03d7def74a8c4348e666"
dependencies = [
"cfg-if",
"core-foundation-sys",
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_abi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ edition = "2021"

[dependencies]
# tidy-alphabetical-start
bitflags = "1.2.1"
bitflags = "2.4.1"
rand = { version = "0.8.4", default-features = false, optional = true }
rand_xoshiro = { version = "0.6.0", optional = true }
rustc_data_structures = { path = "../rustc_data_structures", optional = true }
Expand Down
15 changes: 9 additions & 6 deletions compiler/rustc_abi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,12 @@ pub use layout::LayoutCalculator;
/// instead of implementing everything in `rustc_middle`.
pub trait HashStableContext {}

#[derive(Clone, Copy, PartialEq, Eq, Default)]
#[cfg_attr(feature = "nightly", derive(Encodable, Decodable, HashStable_Generic))]
pub struct ReprFlags(u8);

bitflags! {
#[derive(Default)]
#[cfg_attr(feature = "nightly", derive(Encodable, Decodable, HashStable_Generic))]
pub struct ReprFlags: u8 {
impl ReprFlags: u8 {
const IS_C = 1 << 0;
const IS_SIMD = 1 << 1;
const IS_TRANSPARENT = 1 << 2;
Expand All @@ -42,11 +44,12 @@ bitflags! {
// the seed stored in `ReprOptions.layout_seed`
const RANDOMIZE_LAYOUT = 1 << 4;
// Any of these flags being set prevent field reordering optimisation.
const IS_UNOPTIMISABLE = ReprFlags::IS_C.bits
| ReprFlags::IS_SIMD.bits
| ReprFlags::IS_LINEAR.bits;
const IS_UNOPTIMISABLE = ReprFlags::IS_C.bits()
| ReprFlags::IS_SIMD.bits()
| ReprFlags::IS_LINEAR.bits();
}
}
rustc_data_structures::external_bitflags_debug! { ReprFlags }

#[derive(Copy, Clone, Debug, Eq, PartialEq)]
#[cfg_attr(feature = "nightly", derive(Encodable, Decodable, HashStable_Generic))]
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_ast/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ edition = "2021"

[dependencies]
# tidy-alphabetical-start
bitflags = "1.2.1"
bitflags = "2.4.1"
memchr = "2.5.0"
rustc_data_structures = { path = "../rustc_data_structures" }
rustc_index = { path = "../rustc_index" }
Expand Down
23 changes: 12 additions & 11 deletions compiler/rustc_ast/src/ast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2171,9 +2171,10 @@ pub enum InlineAsmRegOrRegClass {
RegClass(Symbol),
}

#[derive(Clone, Copy, PartialEq, Eq, Hash, Encodable, Decodable, HashStable_Generic)]
pub struct InlineAsmOptions(u16);
bitflags::bitflags! {
#[derive(Encodable, Decodable, HashStable_Generic)]
pub struct InlineAsmOptions: u16 {
impl InlineAsmOptions: u16 {
const PURE = 1 << 0;
const NOMEM = 1 << 1;
const READONLY = 1 << 2;
Expand All @@ -2186,6 +2187,12 @@ bitflags::bitflags! {
}
}

impl std::fmt::Debug for InlineAsmOptions {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
bitflags::parser::to_writer(self, f)
}
}

#[derive(Clone, PartialEq, Encodable, Decodable, Debug, Hash, HashStable_Generic)]
pub enum InlineAsmTemplatePiece {
String(String),
Expand Down Expand Up @@ -2481,15 +2488,6 @@ pub enum Const {
No,
}

impl From<BoundConstness> for Const {
fn from(constness: BoundConstness) -> Self {
match constness {
BoundConstness::Maybe(span) => Self::Yes(span),
BoundConstness::Never => Self::No,
}
}
}

/// Item defaultness.
/// For details see the [RFC #2532](https://github.com/rust-lang/rfcs/pull/2532).
#[derive(Copy, Clone, PartialEq, Encodable, Decodable, Debug, HashStable_Generic)]
Expand Down Expand Up @@ -2543,6 +2541,8 @@ impl BoundPolarity {
pub enum BoundConstness {
/// `Type: Trait`
Never,
/// `Type: const Trait`
Always(Span),
/// `Type: ~const Trait`
Maybe(Span),
}
Expand All @@ -2551,6 +2551,7 @@ impl BoundConstness {
pub fn as_str(self) -> &'static str {
match self {
Self::Never => "",
Self::Always(_) => "const",
Self::Maybe(_) => "~const",
}
}
Expand Down
9 changes: 0 additions & 9 deletions compiler/rustc_ast/src/token.rs
Original file line number Diff line number Diff line change
Expand Up @@ -528,15 +528,6 @@ impl Token {
}
}

/// Returns `true` if the token can appear at the start of a generic bound.
pub fn can_begin_bound(&self) -> bool {
self.is_path_start()
|| self.is_lifetime()
|| self.is_keyword(kw::For)
|| self == &Question
|| self == &OpenDelim(Delimiter::Parenthesis)
}

/// Returns `true` if the token can appear at the start of an item.
pub fn can_begin_item(&self) -> bool {
match self.kind {
Expand Down
Loading

0 comments on commit 39c714b

Please sign in to comment.