718 Commits

Author SHA1 Message Date
Prajwal S N
72c7cd3869
chore: clean up some FIXMEs
Signed-off-by: Prajwal S N <prajwalnadig21@gmail.com>
2025-04-04 17:40:56 +05:30
Lukas Wirth
7a1e9c4b0c ci: Require miri step 2025-03-25 08:10:27 +01:00
Laurențiu Nicola
1259cc52c6 Use zip/deflate-flate2 to avoid BSL-1.0 dep 2025-03-23 13:56:55 +02:00
Lukas Wirth
500ea05aef chore: Bump dependencies 2025-03-23 08:46:10 +01:00
Lukas Wirth
d31301cbe7 refactor: Reduce codegen burden for SyntaxNode and SyntaxToken 2025-03-21 12:14:39 +01:00
Lukas Wirth
d6dc1bf05e refactor: Reduce codegen burden for SyntaxKind 2025-03-21 12:14:39 +01:00
Prajwal S N
1f366e7efe
fix(codegen): do not generate docs with --check
Running `cargo codegen --check` should not generate any mdbook files,
since they are ignored in the repo and used only while releasing a new
copy of the documentation.

Signed-off-by: Prajwal S N <prajwalnadig21@gmail.com>
2025-03-17 14:40:24 +05:30
BenjaminBrienen
1293a5a186 cargo xtask tidy 2025-03-15 21:32:01 +01:00
BenjaminBrienen
7535bb4661 cargo fmt 2025-03-15 21:32:01 +01:00
BenjaminBrienen
70fc7b98c6 edition = "2024" 2025-03-15 21:32:01 +01:00
Lukas Wirth
029878eff9 chore: Drop legacy salsa 2025-03-15 12:02:31 -04:00
David Barsky
74620e64ec internal: port rust-analyzer to new Salsa 2025-03-10 13:30:51 -04:00
David Barsky
7a7ff470ca internal: vendor query-group-macro 2025-03-10 10:12:52 -04:00
Laurențiu Nicola
e039ae794d Use cargo zigbuild for releases 2025-02-26 14:16:09 +02:00
niller-g
18d6e281b3 Fix codegen of parser inline tests runner
When running `cargo codegen` the `crates/parser/test_data/generated/runner.rs` file is only updated when some file in `crates/parser/test_data/inline` changes. However this is not sufficient in all cases
2025-02-23 11:41:34 +01:00
niller-g
7236109f56 Fix parser inline tests codegen panics
When running `cargo codegen` the cwd="rust-analyzer" however when running `cargo test` the cwd="rust-analyzer/xtask" which makes the codegen panic
2025-02-23 11:34:44 +01:00
Josh Rotenberg
5968782ce6 missed the L for the line number 2025-02-19 16:52:12 -08:00
Lukas Wirth
9691da7707
Merge pull request #19180 from joshrotenberg/fix-source-file-url
doc: use fully qualified url for source path
2025-02-19 06:37:01 +00:00
Josh Rotenberg
ea9e179287 use fully qualified url for source path 2025-02-18 12:57:18 -08:00
Benjamin Brienen
e5484d9c73
Fix dead link 2025-02-18 17:22:45 +01:00
Josh Rotenberg
f40ff2d8dc move dev docs to manual
fix formatting
2025-02-17 10:47:27 -08:00
Wilfred Hughes
3251d1caa7 manual: Fix URLs to rustdoc pages
Now that the manual lives at /manual/, we need to use absolute URLs
to link to rustdoc content.
2025-02-11 12:10:32 -08:00
Lukas Wirth
4dc936bfe2 Bump proc-macro2 in xtask 2025-02-05 08:22:20 +01:00
Laurențiu Nicola
b0276dd240 Stop running some release workflows on forks and update old URLs 2025-02-01 08:21:14 +02:00
Wilfred Hughes
deda58e8f1 manual: Convert to mdbook
Split manual.adoc into markdown files, one for each chapter.

For the parts of the manual that are generated from source code doc
comments, update the comments to use markdown syntax and update the
code generators to write to `generated.md` files.

For the weekly release, stop copying the .adoc files to the
`rust-analyzer/rust-analyzer.github.io` at release time. Instead,
we'll sync the manual hourly from this repository.

See https://github.com/rust-analyzer/rust-analyzer.github.io/pull/226
for the sync. This PR should be merged first, and that PR needs to be
merged before the next weekly release.

This change is based on #15795, but rebased and updated. I've also
manually checked each page for markdown syntax issues and fixed any I
encountered.

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
Co-authored-by: Josh Rotenberg <joshrotenberg@gmail.com>
2025-01-24 13:23:22 -08:00
Lukas Wirth
4b6007115a minor: New clippy lints 2025-01-06 17:57:17 +01:00
Chayim Refael Friedman
505e82c19c Add a function to convert a SyntaxKind to its text, where possible
This will also help for the make's quote macro.
2024-12-30 04:01:05 +02:00
Chayim Refael Friedman
737500137f Generate a method for static retrieval of the SyntaxKind of a node, where possible
This will help for the quote macro for `ast::make`.
2024-12-30 03:13:17 +02:00
Lukas Wirth
5ce14b0439 Enforce a current directory being set for spawned commands 2024-12-29 12:51:13 +01:00
Lukas Wirth
5211972743 internal: Split serde derive feature into serde_derive usage
Ideally we'd not have any dependency pull in the derive feature for faster build times, once that is the case this change would have an actual effect.
See https://github.com/matklad/macro-dep-test/blob/master/README.md for context.
2024-12-20 11:55:02 +01:00
Chayim Refael Friedman
0b7a6f38d7 Properly handle different defaults for severity of lints
Previously all lints were assumed to be `#[warn]`, and we had a hand-coded list of `#[allow]` exceptions. Now the severity is autogenerated from rustdoc output.

Also support lints that change status between editions, and the `warnings` lint group.
2024-12-11 20:48:41 +02:00
Laurențiu Nicola
724f161cc9 Bump rustc crates 2024-11-01 13:38:35 +02:00
Lukas Wirth
80e9d014be
Merge pull request #18074 from ChayimFriedman2/typeref-source-map
internal: Build source map for `hir_def::TypeRef`s
2024-10-28 11:01:12 +00:00
Laurențiu Nicola
d481decd06
Merge pull request #18412 from lnicola/windows-no-gz
internal: Stop producing .gz artifacts for Windows
2024-10-28 10:11:29 +00:00
Laurențiu Nicola
47cb838b2c Stop producing .gz artifacts for Windows 2024-10-25 15:14:52 +03:00
Chayim Refael Friedman
061e5d7f71 Shrink Path to 16 bytes
Thanks to the observation (supported by counting) that the vast majority paths have neither generics no type anchors, and thanks to a new datastructure `ThinVecWithHeader` that is essentially `(T, Box<[U]>)` but with the size of a single pointer, we are able to reach this feat.

This (together with `ThinVecWithHeader`) makes the possibility to shrink `TypeRef`, because most types are paths.
2024-10-25 06:44:56 +03:00
Laurențiu Nicola
333952f623 Update changelog generation for merge queues 2024-10-24 20:40:57 +03:00
Lukas Wirth
6c23f25e7f Fix new nightly lints 2024-10-22 11:48:41 +02:00
roife
834ccbffba fix: classify safe as a contextual kw 2024-10-21 02:56:21 +08:00
David Barsky
ccee36e8dd chore: rename salsa to ra_salsa 2024-10-14 10:09:22 -04:00
Lukas Wirth
86658c66b4 Parse builtin#asm expressions 2024-09-04 14:09:03 +02:00
Lukas Wirth
3ad54a74ab Allow xtask::reformat to work without rustup 2024-08-30 16:17:45 +02:00
Lukas Wirth
38c1d6e337 Revert "fix: do not assume rustup is installed in xtask codegen"
This reverts commit 7d9e4fcc07e5de94e37b73436147cdbbaa35dbdc.
2024-08-30 16:15:01 +02:00
Ivar Scholten
7d9e4fcc07 fix: do not assume rustup is installed in xtask codegen
When formatting generated code the xtask crate attempts to run `rustup run stable rustfmt`,
which fails if `rustup` is not installed. This results in test failures when another source manages
the compiler toolchain, for example when using Nix (or any other distro-specific packaging solution):

* xtask::codegen::grammar::test
* xtask::codegen::assists_doc_tests::test

With this commit xtask will first attempt to run `rustup run stable rustfmt`, and if that fails just
plain `rustfmt`. It still validates a stable version is being used.

This allows `cargo test` to pass on systems that do not use `rustup`.
2024-08-27 14:25:13 +02:00
Lukas Wirth
f90bdfc13d internal: Properly check the edition for edition dependent syntax kinds 2024-08-15 15:57:47 +02:00
Lukas Wirth
80483e0622 Allow new license combination 2024-08-12 12:51:47 +02:00
Lukas Wirth
2d15cdb9fc minor: Fix metrics not running 2024-08-05 14:59:27 +02:00
Ralf Jung
83e534923d when josh-proxy screws up the roundtrip, say what the involved commits are 2024-08-01 12:28:02 +02:00
Lukas Wirth
200a01adc4 Generate From impls for Any* nodes 2024-07-25 10:21:58 +02:00
Lukas Wirth
92f5e806f1 Fix edition used for include macro parsing 2024-07-19 20:29:53 +02:00