Lukas Wirth
047b8d9f29
Keep config diagnostics across changes
2024-06-05 14:56:07 +02:00
Lukas Wirth
d537941d1b
Diagnose most incorrect ra-toml config errors
2024-06-05 13:09:49 +02:00
bors
48bbdd6a74
Auto merge of #17348 - regexident:fix-type-or-const-param-source, r=Veykril
...
Use `.get(…)` instead of `[…]` in `TypeOrConstParam::source(…)` and `LifetimeParam::source(…)`
Resolves #17344 .
2024-06-05 10:34:31 +00:00
Vincent Esche
78f31696da
Resolve #17344 by using .get(…)
instead of […]
in TypeOrConstParam::source(…)
...
(… and `LifetimeParam::source(…)`)
2024-06-05 11:03:56 +02:00
Lukas Wirth
c791a3d709
Fix local configs allowing to contain global changes
2024-06-05 10:47:53 +02:00
Lukas Wirth
fb8a2c334f
Shuffle around some of the configs between the levels
2024-06-05 10:47:33 +02:00
Ali Bektas
75409f79fd
Apply requested changes round 3
2024-06-05 10:45:22 +02:00
Ali Bektas
cf97aac994
Apply requested changes round 2
2024-06-05 10:45:22 +02:00
Ali Bektas
23a5f31ff4
Apply suggested changes
2024-06-05 10:45:19 +02:00
bors
52e80658e1
Auto merge of #17347 - Veykril:inv-offset-err, r=Veykril
...
minor: Add debug info to invalid offset error
cc https://github.com/rust-lang/rust-analyzer/issues/17289
2024-06-05 08:21:47 +00:00
Lukas Wirth
5a7f2dd4b0
Add debug info to invalid offset error
2024-06-05 10:20:05 +02:00
ChosenName
14df2a4b7a
fmt
2024-06-04 22:16:08 -06:00
ChosenName
60f67368fe
fmt
2024-06-04 22:12:54 -06:00
ChosenName
bfc7d3f1b2
Update dist.rs
2024-06-04 21:44:07 -06:00
ChosenName
55540f1f85
Update config.rs
2024-06-04 21:39:37 -06:00
ChosenName
7d8125abe7
fmt
2024-06-04 21:35:41 -06:00
ChosenName
82a8e2a357
Fix typos
2024-06-04 21:30:36 -06:00
ChosenName
49806f9ab9
Update config.rs
2024-06-04 21:09:21 -06:00
ChosenName
bf1a3a32bd
Update package.json
2024-06-04 21:08:30 -06:00
bors
29e5cdfb05
Auto merge of #17004 - Veykril:ide-macro-caching, r=Veykril
...
Try caching macro calls more aggressively in Semantics
2024-06-04 14:28:52 +00:00
Lukas Wirth
9349045e09
Use dyn cache for Semantics macro resolution
2024-06-04 16:25:38 +02:00
Lukas Wirth
7d40763c88
Cache parse trees in Semantics
2024-06-04 15:29:24 +02:00
Lukas Wirth
c12f093716
Cache file_to_def
in SourceToDefCtx
2024-06-04 15:23:02 +02:00
Lukas Wirth
97b58f2846
Try caching macro calls more aggressively
2024-06-04 15:23:00 +02:00
bors
f28f15ac6e
Auto merge of #17341 - Veykril:inert-attr, r=Veykril
...
internal: Cleanup some inert attribute stuff
2024-06-04 10:42:15 +00:00
Lukas Wirth
6f0207d594
Cleanup some inert attribute stuff
2024-06-04 12:38:20 +02:00
bors
6bae8e333b
Auto merge of #17282 - jkelleyrtp:jk/filter-by-underscorte, r=Veykril
...
Feat: hide double underscored symbols from symbol search
Fixes #17272 by changing the default behavior of query to skip results that start with `__` (two underscores).
Not sure if this has any far reaching implications - a review would help to understand if this is the right place to do the filtering, and if it's fine to do it by default on the query.
If you type `__` as your search, then we'll show the matching double unders, just in case you actually need the symbol.
2024-06-04 08:37:56 +00:00
Lukas Wirth
0110cfcae0
Recognize __
prefixes for symbol search query
2024-06-04 10:36:04 +02:00
bors
09d7dcc143
Auto merge of #17340 - Veykril:find-path2, r=Veykril
...
internal: Improve `find_path` performance
cc https://github.com/rust-lang/rust-analyzer/issues/17339 , db80216dac
should fix a case where we don't reduce our search space appropriately. This also adds a fuel system which really shouldn't ever be hit, hence why it warns
2024-06-03 18:08:17 +00:00
Lukas Wirth
f1dbb958c8
Add fuel to find_path
2024-06-03 20:07:00 +02:00
Lukas Wirth
f94d34bd72
Remove an allocation in find_path::find_local_import_locations
2024-06-03 19:57:49 +02:00
Lukas Wirth
48822e0941
Simplify
2024-06-03 19:46:40 +02:00
Lukas Wirth
426d01eab0
Deduplicate
2024-06-03 19:26:11 +02:00
Lukas Wirth
db80216dac
Fix find_path search not reducing scope appropriately for foreign items
2024-06-03 19:21:19 +02:00
Lukas Wirth
60fa981df1
Simplify
2024-06-03 19:06:58 +02:00
bors
89218cf29c
Auto merge of #17329 - Nilstrieb:rustc_deprecated_safe_2024, r=Veykril
...
Don't mark `#[rustc_deprecated_safe_2024]` functions as unsafe
`std::env::set_var` will be unsafe in edition 2024, but not before it. I couldn't quite figure out how to check for the span properly, so for now we just turn the false positives into false negatives, which are less bad.
2024-06-03 12:44:21 +00:00
bors
cb6b808185
Auto merge of #17315 - hamirmahal:style/simplify-string-interpolation, r=Veykril
...
style: simplify string interpolation
2024-06-03 12:29:27 +00:00
bors
9edc30a42b
Auto merge of #17312 - regexident:function-fn-ptr-type, r=Veykril
...
Add `Function::fn_ptr_type(…)` for obtaining name-erased function type
The use case of this function if being able to group functions by their function ptr type.
cc `@flodiebold`
2024-06-03 12:16:29 +00:00
bors
5ac4be8167
Auto merge of #17333 - DropDemBits:extract-format-args-snippet-cap, r=Veykril
...
fix: Only generate snippets for `extract_expressions_from_format_string` if snippets are supported
Part of #17332
Fixes `extract_expressions_from_format_string` so that it doesn't generate snippets if the client doesn't support it.
2024-06-03 12:03:18 +00:00
bors
7852a4c775
Auto merge of #17337 - Veykril:assert-info, r=Veykril
...
Add path info to `AbsPathBuf::assert`'s assert
cc https://github.com/rust-lang/rust-analyzer/issues/17335
2024-06-02 19:30:55 +00:00
Lukas Wirth
cdb4f9631c
Add path info to AbsPathBuf::assert
's assert
2024-06-02 21:28:25 +02:00
DropDemBits
a741bb2055
fix typos & formatting
2024-06-02 14:09:36 -04:00
DropDemBits
cf9401049c
Make extract_expressions_from_format_string
only use snippets when available
2024-06-02 11:47:05 -04:00
DropDemBits
e989f22015
Add ast::Expr::parse
2024-06-02 11:17:52 -04:00
DropDemBits
c4573b26f6
minor: tidy up Parse
a little bit
...
- Add doc comments to some `Parse` methods
- Uses `Parse::new` more
2024-06-02 11:10:39 -04:00
DropDemBits
3b763a847a
Add tt_from_syntax
...
Used for inserting syntax nodes into existing token trees
2024-06-02 11:10:07 -04:00
Nilstrieb
0e1353bebd
Don't mark #[rustc_deprecated_safe_2024]
functions as unsafe
...
`std::env::set_var` will be unsafe in edition 2024, but not before it.
I couldn't quite figure out how to check for the span properly, so for now
we just turn the false positives into false negatives, which are less bad.
2024-06-02 15:04:26 +02:00
bors
6b9baed80e
Auto merge of #17328 - Veykril:derive-helper-completions, r=Veykril
...
feat: Enable completions within derive helper attributes
![Code_zG5qInoQ6B](https://github.com/rust-lang/rust-analyzer/assets/3757771/db30b98d-4981-45e3-83a5-7ff23fbd3f66 )
2024-06-02 07:47:13 +00:00
Lukas Wirth
3116f76fba
feat: Enable completions within derive helper attributes
2024-06-02 09:45:57 +02:00
bors
ca5568182d
Auto merge of #17326 - Veykril:fix-attr-derive-container, r=Veykril
...
fix: Fix container search failing for tokens originating within derive attributes
2024-06-01 18:58:59 +00:00