diff --git a/Cargo.lock b/Cargo.lock index 632c0b5ed521..5e0813484cf0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -616,7 +616,7 @@ dependencies = [ "oorandom", "project-model", "ra-ap-rustc_abi", - "ra-ap-rustc_index", + "ra-ap-rustc_index 0.52.0", "ra-ap-rustc_pattern_analysis", "rustc-hash", "scoped-tls", @@ -1260,7 +1260,7 @@ dependencies = [ "drop_bomb", "expect-test", "limit", - "ra-ap-rustc_lexer", + "ra-ap-rustc_lexer 0.52.0", "sourcegen", "stdx", "tracing", @@ -1367,7 +1367,7 @@ dependencies = [ "paths", "proc-macro-api", "proc-macro-test", - "ra-ap-rustc_lexer", + "ra-ap-rustc_lexer 0.52.0", "span", "stdx", "tt", @@ -1486,12 +1486,12 @@ dependencies = [ [[package]] name = "ra-ap-rustc_abi" -version = "0.44.0" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8709df2a746f055316bc0c62bd30948695a25e734863bf6e1f9755403e010ab" +checksum = "fe54b7dc88e196597b450ff3e5b7f0ca65ac6108a0075c38b1fa35e8f94ed317" dependencies = [ "bitflags 2.5.0", - "ra-ap-rustc_index", + "ra-ap-rustc_index 0.52.0", "tracing", ] @@ -1502,7 +1502,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ad68bacffb87dcdbb23a3ce11261375078aaa06b85d348c49f39ffd5510dc20" dependencies = [ "arrayvec", - "ra-ap-rustc_index_macros", + "ra-ap-rustc_index_macros 0.44.0", + "smallvec", +] + +[[package]] +name = "ra-ap-rustc_index" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d909bfc2f9416da6102899496ea73cf2646d411ed28da38f2b95a26c620be32" +dependencies = [ + "arrayvec", + "ra-ap-rustc_index_macros 0.52.0", "smallvec", ] @@ -1518,6 +1529,18 @@ dependencies = [ "synstructure", ] +[[package]] +name = "ra-ap-rustc_index_macros" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5acb12ee148d25b3acb75b30edeb3dd6a123aed8c4cc4fa2521e5829b8ac6c19" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "synstructure", +] + [[package]] name = "ra-ap-rustc_lexer" version = "0.44.0" @@ -1528,14 +1551,24 @@ dependencies = [ "unicode-xid", ] +[[package]] +name = "ra-ap-rustc_lexer" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "238b016b75284d1614d7b139e3cf6ddf2ccd8278ce8940ac5844bae50b12a45b" +dependencies = [ + "unicode-properties", + "unicode-xid", +] + [[package]] name = "ra-ap-rustc_parse_format" version = "0.44.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0bcf9ff5edbf784b67b8ad5e03a068f1300fcc24062c0d476b3018965135d933" dependencies = [ - "ra-ap-rustc_index", - "ra-ap-rustc_lexer", + "ra-ap-rustc_index 0.44.0", + "ra-ap-rustc_lexer 0.44.0", ] [[package]] @@ -1544,7 +1577,7 @@ version = "0.44.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d63d1e1d5b2a13273cee1a10011147418f40e12b70f70578ce1dee0f1cafc334" dependencies = [ - "ra-ap-rustc_index", + "ra-ap-rustc_index 0.44.0", "rustc-hash", "rustc_apfloat", "smallvec", @@ -1956,7 +1989,7 @@ dependencies = [ "itertools", "once_cell", "parser", - "ra-ap-rustc_lexer", + "ra-ap-rustc_lexer 0.52.0", "rayon", "rowan", "rustc-hash", diff --git a/Cargo.toml b/Cargo.toml index 635620cd7b4f..1a0c5b640059 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -85,10 +85,10 @@ tt = { path = "./crates/tt", version = "0.0.0" } vfs-notify = { path = "./crates/vfs-notify", version = "0.0.0" } vfs = { path = "./crates/vfs", version = "0.0.0" } -ra-ap-rustc_lexer = { version = "0.44.0", default-features = false } +ra-ap-rustc_lexer = { version = "0.52.0", default-features = false } ra-ap-rustc_parse_format = { version = "0.44.0", default-features = false } -ra-ap-rustc_index = { version = "0.44.0", default-features = false } -ra-ap-rustc_abi = { version = "0.44.0", default-features = false } +ra-ap-rustc_index = { version = "0.52.0", default-features = false } +ra-ap-rustc_abi = { version = "0.52.0", default-features = false } ra-ap-rustc_pattern_analysis = { version = "0.44.0", default-features = false } # local crates that aren't published to crates.io. These should not have versions. diff --git a/crates/hir-def/src/attr/builtin.rs b/crates/hir-def/src/attr/builtin.rs index 55b9a1dfdcb9..1fba2e2e4d34 100644 --- a/crates/hir-def/src/attr/builtin.rs +++ b/crates/hir-def/src/attr/builtin.rs @@ -207,7 +207,6 @@ pub const INERT_ATTRIBUTES: &[BuiltinAttribute] = &[ ), // Entry point: - gated!(unix_sigpipe, Normal, template!(Word, NameValueStr: "inherit|sig_ign|sig_dfl"), ErrorFollowing, experimental!(unix_sigpipe)), ungated!(start, Normal, template!(Word), WarnFollowing), ungated!(no_start, CrateLevel, template!(Word), WarnFollowing), ungated!(no_main, CrateLevel, template!(Word), WarnFollowing), diff --git a/crates/hir-ty/src/layout.rs b/crates/hir-ty/src/layout.rs index dd949e26c2ab..d9fd029d378c 100644 --- a/crates/hir-ty/src/layout.rs +++ b/crates/hir-ty/src/layout.rs @@ -6,8 +6,8 @@ use base_db::salsa::Cycle; use chalk_ir::{AdtId, FloatTy, IntTy, TyKind, UintTy}; use hir_def::{ layout::{ - Abi, FieldsShape, Integer, LayoutCalculator, LayoutS, Primitive, ReprOptions, Scalar, Size, - StructKind, TargetDataLayout, WrappingRange, + Abi, FieldsShape, Float, Integer, LayoutCalculator, LayoutS, Primitive, ReprOptions, + Scalar, Size, StructKind, TargetDataLayout, WrappingRange, }, LocalFieldId, StructId, }; @@ -264,10 +264,10 @@ pub fn layout_of_ty_query( ), chalk_ir::Scalar::Float(f) => scalar( dl, - match f { - FloatTy::F32 => Primitive::F32, - FloatTy::F64 => Primitive::F64, - }, + Primitive::Float(match f { + FloatTy::F32 => Float::F32, + FloatTy::F64 => Float::F64, + }), ), }, TyKind::Tuple(len, tys) => { diff --git a/crates/ide-db/src/generated/lints.rs b/crates/ide-db/src/generated/lints.rs index d50088e6cf1d..c92d4e78ffa7 100644 --- a/crates/ide-db/src/generated/lints.rs +++ b/crates/ide-db/src/generated/lints.rs @@ -3869,7 +3869,7 @@ use std::ops::{Coroutine, CoroutineState}; use std::pin::Pin; fn main() { - let mut coroutine = || { + let mut coroutine = #[coroutine] || { yield 1; return "foo" }; @@ -3901,7 +3901,7 @@ use std::ops::Coroutine; use std::pin::Pin; fn main() { - let mut coroutine = || { + let mut coroutine = #[coroutine] || { println!("2"); yield; println!("4"); @@ -4007,7 +4007,7 @@ use std::pin::Pin; fn main() { let ret = "foo"; - let mut coroutine = move || { + let mut coroutine = #[coroutine] move || { yield 1; return ret }; diff --git a/crates/parser/src/lexed_str.rs b/crates/parser/src/lexed_str.rs index 48e4c8a6225c..e5fec67de706 100644 --- a/crates/parser/src/lexed_str.rs +++ b/crates/parser/src/lexed_str.rs @@ -178,7 +178,7 @@ impl<'a> Converter<'a> { rustc_lexer::TokenKind::Ident => { SyntaxKind::from_keyword(token_text).unwrap_or(IDENT) } - rustc_lexer::TokenKind::InvalidIdent => { + rustc_lexer::TokenKind::InvalidPrefix | rustc_lexer::TokenKind::InvalidIdent => { err = "Ident contains invalid characters"; IDENT } diff --git a/rust-version b/rust-version index e69de29bb2d1..ca148cecbebe 100644 --- a/rust-version +++ b/rust-version @@ -0,0 +1 @@ +94be5ab448f9bd0209e3ec20fc355643772da7d0