Commit graph

134 commits

Author SHA1 Message Date
Chayim Refael Friedman
de312d0c71 Don't run doctests 2025-06-23 00:50:22 +03:00
Lukas Wirth
03f1003637 chore: Start infesting ide crates with 'db lifetime 2025-06-17 10:42:38 +02:00
Lukas Wirth
23712aea06 cargo upgrade 2025-06-13 10:08:20 +02:00
Lukas Wirth
8d9b318a85 perf: Request cancellation while processing changed files 2025-05-08 10:18:17 +02:00
Lukas Wirth
d11dbf648f Cleanup cfg check handling in expression store lowering 2025-04-29 11:44:11 +02:00
Lukas Wirth
7d9b839f9c refactor: Clean up cache priming cancellation handling 2025-04-29 10:40:31 +02:00
David Barsky
3e15dbc85f internal: fix NameGenerator's and AnyMap's rustdocs 2025-04-09 12:44:52 -04:00
BenjaminBrienen
428ee50540 upstream stdx changes 2025-04-06 23:55:12 +02:00
BenjaminBrienen
2462624a7d prefer default over new 2025-04-04 15:49:50 +02:00
Lukas Wirth
dcd742301e refactor: Replace custom ThinVec with thin-vec crate 2025-03-24 13:44:13 +01:00
Lukas Wirth
500ea05aef chore: Bump dependencies 2025-03-23 08:46:10 +01:00
Lukas Wirth
d4122434dd chore: Remove unused dependencies 2025-03-23 08:08:17 +01:00
BenjaminBrienen
7535bb4661 cargo fmt 2025-03-15 21:32:01 +01:00
BenjaminBrienen
b19ef6b046 fix doc tests 2025-02-27 14:58:46 +01:00
BenjaminBrienen
bd7375a58f enable doctest 2025-02-27 14:58:46 +01:00
Lukas Wirth
9a462b7c36 Vendor always-assert 2025-02-24 14:00:34 +01:00
Julian Eager
5897755f22 simplify panic_context 2025-02-08 01:39:07 +08:00
Lukas Wirth
5ac4e9769c Prevent panics from tearing down worker threads 2025-02-04 15:03:35 +01:00
Laurențiu Nicola
d01fb4d45a Bump windows-sys 2025-01-17 21:28:11 +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
MoskalykA
41fa877362 Start using Option::is_none_or 2024-10-26 09:39:04 +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
mo8it
0b541ebbaa Use crossbeam-channel from the workspace 2024-08-09 23:48:03 +02:00
Vincent Esche
7dec7e92ea Replace [package.repository] = "…" of published crates with [package.repository.workspace] = true 2024-08-06 00:26:42 +02:00
Vincent Esche
6f329e6d5b Add repository URL for published crates' missing [package.repository] fields 2024-08-06 00:25:02 +02:00
Vincent Esche
b5b0f4bc5a Replace "TBD" with more helpful desciptions in published crates' [package.description] fields 2024-08-06 00:25:02 +02:00
Laurențiu Nicola
900db35537 Merge from rust-lang/rust 2024-07-28 17:19:33 +03:00
Laurențiu Nicola
b392eb4eb5 Fix and enable unsafe_op_in_unsafe_fn 2024-07-25 08:41:30 +03:00
Mark Rousskov
f410a2d02f Allow deprecated temporarily to unblock version bump 2024-07-20 15:51:58 -04:00
Laurențiu Nicola
bd6de0cb57 Merge from rust-lang/rust 2024-07-11 20:06:05 +03:00
Maybe Lapkin
0cea755154 Delete CloneAny from rust-analyzer's fork of AnyMap
...because it's very sketchy and causes FCWs.
In this case it *is* actually sound, but still.

I should write a better fork of anymap...
2024-07-04 17:57:31 +02:00
Lukas Wirth
21a3d01875 Remove inline rust_2018_idioms, unused_lifetimes lint warn, Cargo.toml already enforces this 2024-06-30 15:23:54 +02:00
Wilfred Hughes
d68e549205 internal: Fix rustdoc warnings
`cargo doc` generates a bunch of warnings on rust-analyzer. Fix all the
bare URL and empty code block warnings.
2024-06-13 17:29:10 -07:00
Lukas Wirth
793396c624 Track hashes for file contents 2024-05-14 11:21:04 +02:00
Kenny Kerr
99e2530583 Update rust-analyzer to use windows-sys crate 2024-05-01 09:04:13 -05:00
Lukas Wirth
d085ade631 Remove dead test code 2024-03-14 16:24:51 +01:00
hkalbasi
44be2432f5 Add test explorer 2024-03-06 00:05:29 +03:30
Johannes Altmanninger
30b992e95a Deduplicate references to macro argument
Commit 6a06f6f72 (Deduplicate reference search results, 2022-11-07) deduplicates references
within each definition.

There is an edge case when requesting references of a macro argument.  Apparently, our
descend_into_macros() stanza in references.rs produces a cartesian product of
- references inside the macro times
- times references outside the macro.

Since the above deduplication only applies to the references within a single definition, we
return them all, leading to many redundant references.

Work around this by deduplicating definitions as well.  Perhaps there is a better fix to not
produce this cartesian product in the first place; but I think at least for definitions the
problem would remain; a macro can contain multiple definitions of the same name, but since the
navigation target will be the unresolved location, it's the same for all of them.

We can't use unique() because we don't want to drop references that don't have a declaration
(though I dont' have an example for this case).

I discovered this working with the "bitflags" macro from the crate of the same name.

Fixes #16357
2024-02-19 12:23:59 +01:00
Lukas Wirth
9e8a0fae0c Lint debug prints and disallowed types with clippy 2024-02-01 17:57:27 +01:00
bors
850ba2fb63 Auto merge of #16451 - Urhengulas:satisfy-clippy, r=Veykril
internal: Work through temporarily allowed clippy lints, part 2

Another follow-up to https://github.com/rust-lang/rust-analyzer/pull/16401.
2024-02-01 14:23:18 +00:00
Lukas Wirth
23f4b7f45f Remove stdx::eprintln overwrite 2024-01-31 22:06:05 +01:00
Johann Hemmann
771c6c9271 format_collect 2024-01-31 19:06:36 +01:00
David Barsky
e1ea7c8844 internal: switch to tracing from log
This commit also adds `tracing` to NotificationDispatcher/RequestDispatcher,
bumps `rust-analyzer-salsa` to 0.17.0-pre.6, `always-assert` to 0.2, and
removes the homegrown `hprof` implementation in favor of a vendored
tracing-span-tree.
2024-01-30 12:27:31 -05:00
Lukas Wirth
8a5829cf28 Re-order mod declarations 2024-01-27 11:02:34 +01:00
Lukas Wirth
6cf7b5f8d7 Don't parse intra doc links as syntax trees 2024-01-26 20:00:47 +01:00
Lukas Wirth
5a343415e8 Add some size assertions 2024-01-26 19:28:39 +01:00
davidsemakula
1f91c487a2 move is_upper_snake_case to stdx 2024-01-16 13:37:22 +03:00
Lukas Wirth
9b3052104c internal: Rewrite ImportMap::search_dependencies 2024-01-04 17:26:00 +01:00
Tetsuharu Ohzeki
efc87092b3 Use Cargo's [workspace.lints.*] to config clippy 2023-12-29 23:51:32 +09:00
bors
be035e80e8 Auto merge of #118817 - lnicola:sync-from-ra, r=lnicola
Subtree update of `rust-analyzer`

r? `@ghost`
2023-12-12 08:22:37 +00:00