Skip to content

Commit 98c2b4c

Browse files
committed
Auto merge of #137959 - matthiaskrgr:rollup-62vjvwr, r=matthiaskrgr
Rollup of 12 pull requests Successful merges: - #135767 (Future incompatibility warning `unsupported_fn_ptr_calling_conventions`: Also warn in dependencies) - #137852 (Remove layouting dead code for non-array SIMD types.) - #137863 (Fix pretty printing of unsafe binders) - #137882 (do not build additional stage on compiler paths) - #137894 (Revert "store ScalarPair via memset when one side is undef and the other side can be memset") - #137902 (Make `ast::TokenKind` more like `lexer::TokenKind`) - #137921 (Subtree update of `rust-analyzer`) - #137922 (A few cleanups after the removal of `cfg(not(parallel))`) - #137939 (fix order on shl impl) - #137946 (Fix docker run-local docs) - #137955 (Always allow rustdoc-json tests to contain long lines) - #137958 (triagebot.toml: Don't label `test/rustdoc-json` as A-rustdoc-search) r? `@ghost` `@rustbot` modify labels: rollup
2 parents c001c2a + fdb93c1 commit 98c2b4c

File tree

207 files changed

+5985
-4207
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

207 files changed

+5985
-4207
lines changed

Diff for: .github/workflows/autopublish.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111

1212
jobs:
1313
publish:
14-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
14+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
1515
name: publish
1616
runs-on: ubuntu-latest
1717
steps:

Diff for: .github/workflows/ci.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ jobs:
174174
- name: Install Nodejs
175175
uses: actions/setup-node@v4
176176
with:
177-
node-version: 18
177+
node-version: 22
178178
if: needs.changes.outputs.typescript == 'true'
179179

180180
- name: Install xvfb

Diff for: .github/workflows/fuzz.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ env:
1919

2020
jobs:
2121
rust:
22-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
22+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
2323
name: Rust
2424
runs-on: ubuntu-latest
2525
env:

Diff for: .github/workflows/publish-libs.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99

1010
jobs:
1111
publish-libs:
12-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
12+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
1313
name: publish
1414
runs-on: ubuntu-latest
1515
steps:

Diff for: .github/workflows/release.yaml

+27-32
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@ env:
1717
RUSTUP_MAX_RETRIES: 10
1818
FETCH_DEPTH: 0 # pull in the tags for the version string
1919
MACOSX_DEPLOYMENT_TARGET: 13.0
20-
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: aarch64-linux-gnu-gcc
21-
CARGO_TARGET_ARM_UNKNOWN_LINUX_GNUEABIHF_LINKER: arm-linux-gnueabihf-gcc
20+
ZIG_VERSION: 0.13.0
21+
ZIGBUILD_VERSION: 0.19.8
2222

2323
jobs:
2424
dist:
25-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
25+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
2626
strategy:
2727
matrix:
2828
include:
@@ -36,13 +36,15 @@ jobs:
3636
code-target: win32-arm64
3737
- os: ubuntu-latest
3838
target: x86_64-unknown-linux-gnu
39+
zig_target: x86_64-unknown-linux-gnu.2.28
3940
code-target: linux-x64
40-
container: rockylinux:8
4141
- os: ubuntu-latest
4242
target: aarch64-unknown-linux-gnu
43+
zig_target: aarch64-unknown-linux-gnu.2.28
4344
code-target: linux-arm64
4445
- os: ubuntu-latest
4546
target: arm-unknown-linux-gnueabihf
47+
zig_target: arm-unknown-linux-gnueabihf.2.28
4648
code-target: linux-armhf
4749
- os: macos-13
4850
target: x86_64-apple-darwin
@@ -64,40 +66,33 @@ jobs:
6466
with:
6567
fetch-depth: ${{ env.FETCH_DEPTH }}
6668

67-
- name: Install toolchain dependencies
68-
if: matrix.container == 'rockylinux:8'
69-
shell: bash
70-
run: |
71-
dnf install -y gcc
72-
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL "https://sh.rustup.rs" | sh -s -- --profile minimal --default-toolchain none -y
73-
echo "${CARGO_HOME:-$HOME/.cargo}/bin" >> $GITHUB_PATH
69+
- name: Install Node.js toolchain
70+
uses: actions/setup-node@v4
71+
with:
72+
node-version: 22
7473

7574
- name: Install Rust toolchain
7675
run: |
7776
rustup update --no-self-update stable
78-
rustup target add ${{ matrix.target }}
7977
rustup component add rust-src
78+
rustup target add ${{ matrix.target }}
8079
81-
- name: Install Node.js
82-
uses: actions/setup-node@v4
83-
with:
84-
node-version: 18
85-
86-
- name: Update apt repositories
87-
if: matrix.target == 'aarch64-unknown-linux-gnu' || matrix.target == 'arm-unknown-linux-gnueabihf'
88-
run: sudo apt-get update
89-
90-
- name: Install AArch64 target toolchain
91-
if: matrix.target == 'aarch64-unknown-linux-gnu'
92-
run: sudo apt-get install gcc-aarch64-linux-gnu
93-
94-
- name: Install ARM target toolchain
95-
if: matrix.target == 'arm-unknown-linux-gnueabihf'
96-
run: sudo apt-get install gcc-arm-linux-gnueabihf
80+
- name: Install Zig toolchain
81+
if: ${{ matrix.zig_target }}
82+
run: |
83+
which cargo
84+
curl -L "https://ziglang.org/download/${ZIG_VERSION}/zig-linux-$(uname -m)-${ZIG_VERSION}.tar.xz" | sudo tar JxC /usr/local
85+
sudo ln -s "/usr/local/zig-linux-$(uname -m)-${ZIG_VERSION}/zig" /usr/local/bin/zig
86+
curl -L "https://github.com/rust-cross/cargo-zigbuild/releases/download/v${ZIGBUILD_VERSION}/cargo-zigbuild-v${ZIGBUILD_VERSION}.x86_64-unknown-linux-musl.tar.gz" | tar zxC ~/.cargo/bin
9787
98-
- name: Dist
88+
- name: Dist (plain)
89+
if: ${{ !matrix.zig_target }}
9990
run: cargo xtask dist --client-patch-version ${{ github.run_number }}
10091

92+
- name: Dist (using zigbuild)
93+
if: ${{ matrix.zig_target }}
94+
run: RA_TARGET=${{ matrix.zig_target}} cargo xtask dist --client-patch-version ${{ github.run_number }} --zig
95+
10196
- run: npm ci
10297
working-directory: editors/code
10398

@@ -139,7 +134,7 @@ jobs:
139134
path: ./dist
140135

141136
dist-x86_64-unknown-linux-musl:
142-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
137+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
143138
name: dist (x86_64-unknown-linux-musl)
144139
runs-on: ubuntu-latest
145140
env:
@@ -185,15 +180,15 @@ jobs:
185180
path: ./dist
186181

187182
publish:
188-
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event.action == 'workflow_dispatch' }}
183+
if: ${{ github.repository == 'rust-lang/rust-analyzer' || github.event_name == 'workflow_dispatch' }}
189184
name: publish
190185
runs-on: ubuntu-latest
191186
needs: ["dist", "dist-x86_64-unknown-linux-musl"]
192187
steps:
193188
- name: Install Nodejs
194189
uses: actions/setup-node@v4
195190
with:
196-
node-version: 20
191+
node-version: 22
197192

198193
- run: echo "TAG=$(date --iso -u)" >> $GITHUB_ENV
199194
if: github.ref == 'refs/heads/release'

Diff for: .typos.toml

+2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ extend-ignore-re = [
1818
"INOUT",
1919
"optin",
2020
"=Pn",
21+
# ignore `// spellchecker:off` until `// spellchecker:on`
22+
"(?s)(#|//)\\s*spellchecker:off.*?\\n\\s*(#|//)\\s*spellchecker:on",
2123
]
2224

2325
[default.extend-words]

Diff for: Cargo.lock

+15-18
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: Cargo.toml

+6-7
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ salsa.opt-level = 3
2525
miniz_oxide.opt-level = 3
2626

2727
[profile.release]
28-
incremental = true
2928
# Set this to 1 or 2 to get more useful backtraces in debugger.
3029
debug = 0
3130

@@ -86,12 +85,12 @@ vfs-notify = { path = "./crates/vfs-notify", version = "0.0.0" }
8685
vfs = { path = "./crates/vfs", version = "0.0.0" }
8786
edition = { path = "./crates/edition", version = "0.0.0" }
8887

89-
ra-ap-rustc_hashes = { version = "0.97", default-features = false }
90-
ra-ap-rustc_lexer = { version = "0.97", default-features = false }
91-
ra-ap-rustc_parse_format = { version = "0.97", default-features = false }
92-
ra-ap-rustc_index = { version = "0.97", default-features = false }
93-
ra-ap-rustc_abi = { version = "0.97", default-features = false }
94-
ra-ap-rustc_pattern_analysis = { version = "0.97", default-features = false }
88+
ra-ap-rustc_hashes = { version = "0.98", default-features = false }
89+
ra-ap-rustc_lexer = { version = "0.98", default-features = false }
90+
ra-ap-rustc_parse_format = { version = "0.98", default-features = false }
91+
ra-ap-rustc_index = { version = "0.98", default-features = false }
92+
ra-ap-rustc_abi = { version = "0.98", default-features = false }
93+
ra-ap-rustc_pattern_analysis = { version = "0.98", default-features = false }
9594

9695
# local crates that aren't published to crates.io. These should not have versions.
9796

Diff for: crates/base-db/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ license.workspace = true
1010
rust-version.workspace = true
1111

1212
[lib]
13-
doctest = false
1413

1514
[dependencies]
1615
lz4_flex = { version = "0.11", default-features = false }

Diff for: crates/cfg/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ license.workspace = true
1010
rust-version.workspace = true
1111

1212
[lib]
13-
doctest = false
1413

1514
[dependencies]
1615
rustc-hash.workspace = true

Diff for: crates/hir-def/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ license.workspace = true
1010
rust-version.workspace = true
1111

1212
[lib]
13-
doctest = false
1413

1514
[dependencies]
1615
arrayvec.workspace = true

Diff for: crates/hir-def/src/dyn_map.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@
55
//!
66
//! It is used like this:
77
//!
8-
//! ```
8+
//! ```ignore
9+
//! # use hir_def::dyn_map::DynMap;
10+
//! # use hir_def::dyn_map::Key;
911
//! // keys define submaps of a `DynMap`
1012
//! const STRING_TO_U32: Key<String, u32> = Key::new();
1113
//! const U32_TO_VEC: Key<u32, Vec<bool>> = Key::new();

Diff for: crates/hir-def/src/item_tree.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -883,20 +883,20 @@ pub struct UseTree {
883883

884884
#[derive(Debug, Clone, Eq, PartialEq)]
885885
pub enum UseTreeKind {
886-
/// ```
886+
/// ```ignore
887887
/// use path::to::Item;
888888
/// use path::to::Item as Renamed;
889889
/// use path::to::Trait as _;
890890
/// ```
891891
Single { path: Interned<ModPath>, alias: Option<ImportAlias> },
892892

893-
/// ```
893+
/// ```ignore
894894
/// use *; // (invalid, but can occur in nested tree)
895895
/// use path::*;
896896
/// ```
897897
Glob { path: Option<Interned<ModPath>> },
898898

899-
/// ```
899+
/// ```ignore
900900
/// use prefix::{self, Item, ...};
901901
/// ```
902902
Prefixed { prefix: Option<Interned<ModPath>>, list: Box<[UseTree]> },

Diff for: crates/hir-def/src/macro_expansion_tests/mod.rs

+7-3
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use hir_expand::{
2222
db::ExpandDatabase,
2323
proc_macro::{ProcMacro, ProcMacroExpander, ProcMacroExpansionError, ProcMacroKind},
2424
span_map::SpanMapRef,
25-
InFile, MacroCallKind, MacroFileId, MacroFileIdExt,
25+
InFile, MacroCallKind, MacroFileId, MacroFileIdExt, MacroKind,
2626
};
2727
use intern::Symbol;
2828
use itertools::Itertools;
@@ -211,7 +211,11 @@ pub fn identity_when_valid(_attr: TokenStream, item: TokenStream) -> TokenStream
211211

212212
if let Some(src) = src {
213213
if let Some(file_id) = src.file_id.macro_file() {
214-
if file_id.is_attr_macro(&db) || file_id.is_custom_derive(&db) {
214+
if let MacroKind::Derive
215+
| MacroKind::DeriveBuiltIn
216+
| MacroKind::Attr
217+
| MacroKind::AttrBuiltIn = file_id.kind(&db)
218+
{
215219
let call = file_id.call_node(&db);
216220
let mut show_spans = false;
217221
let mut show_ctxt = false;
@@ -236,7 +240,7 @@ pub fn identity_when_valid(_attr: TokenStream, item: TokenStream) -> TokenStream
236240
for impl_id in def_map[local_id].scope.impls() {
237241
let src = impl_id.lookup(&db).source(&db);
238242
if let Some(macro_file) = src.file_id.macro_file() {
239-
if macro_file.is_builtin_derive(&db) {
243+
if let MacroKind::DeriveBuiltIn | MacroKind::Derive = macro_file.kind(&db) {
240244
let pp = pretty_print_macro_expansion(
241245
src.value.syntax().clone(),
242246
db.span_map(macro_file.into()).as_ref(),

Diff for: crates/hir-def/src/nameres/mod_resolution.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ impl DirPath {
134134
/// So this is the case which doesn't really work I think if we try to be
135135
/// 100% platform agnostic:
136136
///
137-
/// ```
137+
/// ```ignore
138138
/// mod a {
139139
/// #[path="C://sad/face"]
140140
/// mod b { mod c; }

0 commit comments

Comments
 (0)