aboutsummaryrefslogtreecommitdiff
path: root/crates
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | Use format_toJonas Schievink2020-10-231-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | | Update crates/cfg/src/cfg_expr.rsJonas Schievink2020-10-221-1/+1
| | | | | | | | | | | | | | | | | | Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | | Emit better #[cfg] diagnosticsJonas Schievink2020-10-229-65/+124
| | | | | |
| * | | | | Fix typoJonas Schievink2020-10-222-1/+2
| | | | | |
| * | | | | Implement DNF-based `#[cfg]` introspectionJonas Schievink2020-10-224-2/+621
| | | | | |
| * | | | | Simplify cfg representationJonas Schievink2020-10-213-31/+41
| | | | | |
* | | | | | Insert ref for completionsadamrk2020-10-225-26/+132
| | | | | |
* | | | | | Merge #6326bors[bot]2020-10-221-1/+28
|\ \ \ \ \ \ | |_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6326: hide paramater inlay hints for cloned vars if applicable r=SomeoneToIgnore a=Veykril This causes `foo.clone()` parameters to be handled as if they were just `foo` parameters for inlay hint logic. Fixes #6315 Co-authored-by: Lukas Wirth <[email protected]>
| * | | | | Hide paramater inlay hints for cloned vars if applicableLukas Wirth2020-10-221-1/+28
| | |_|/ / | |/| | |
* | | | | Merge #6319bors[bot]2020-10-222-3/+34
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6319: Properly identify camel cased acronyms as UpperCamelCase r=popzxc a=ArifRoktim This closes #6305. Co-authored-by: Arif Roktim <[email protected]>
| * | | | | Properly identify camel cased acronyms as UpperCamelCaseArif Roktim2020-10-212-3/+34
| |/ / / /
| | | | |
| \ \ \ \
*-. \ \ \ \ Merge #6320 #6321bors[bot]2020-10-221-4/+24
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6320: Textmate grammar: prevent line comments from breaking block comments (closes #6281) r=matklad a=dustypomerleau Fixes https://github.com/rust-analyzer/rust-analyzer/issues/6281. Previously, line comments were able to break block comments by essentially commenting out the closing `*/`, resulting in a never-ending comment. This PR splits block comments into a separate repository group to fix this problem. Since the comment scopes also include ignored parameters and inferred types, I've added the change proposed by @bnjjj in https://github.com/rust-analyzer/rust-analyzer/pull/6317, in order to close https://github.com/rust-analyzer/rust-analyzer/issues/6311 as well. 6321: Fix opening module documentation opening parent documentation instead r=matklad a=zacps The whole path/URL joining code is kind of ugly which is what led to this, but at the same time I don't really want to rewrite it right now... Fixes https://github.com/rust-analyzer/rust-analyzer/issues/6286 Co-authored-by: Dusty Pomerleau <[email protected]> Co-authored-by: Zac Pullar-Strecker <[email protected]>
| | * | | | | Fix opening module documentation opening parent documentation insteadZac Pullar-Strecker2020-10-221-4/+24
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The whole path/URL joining code is kind of ugly which is what led to this, but at the same time I don't really want to rewrite it right now...
* | | | | | Merge #6314bors[bot]2020-10-221-2/+40
|\ \ \ \ \ \ | |/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6314: generate assist respect cfg attributes r=matklad a=bnjjj close #6312 Co-authored-by: Benjamin Coenen <[email protected]>
| * | | | | generate_impl assist respect cfg attributes #6312Benjamin Coenen2020-10-221-2/+40
| |/ / / / | | | | | | | | | | | | | | | Signed-off-by: Benjamin Coenen <[email protected]>
* | | | | Merge #6307bors[bot]2020-10-213-2/+99
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6307: Add whitelist of safe intrinsics r=frazar a=frazar This PR should fix #5996, where intrinsic operations where all marked as unsafe. I'm rather new to this codebase, so I might be doing something *very* wrong. Please forgive me! In particular, I'm not sure how to "check that we are in extern `rust-intrinsics`" as mentioned [in this comment](https://github.com/rust-analyzer/rust-analyzer/issues/5996#issuecomment-709234802). Co-authored-by: Francesco Zardi <[email protected]>
| * | | | Refactor is_intrinsic_fn_unsafe() and make it privateFrancesco Zardi2020-10-211-39/+42
| | | | |
| * | | | Move safe intrinsic testsFrancesco Zardi2020-10-212-20/+18
| | | | |
| * | | | Fix typo in commentFrancesco Zardi2020-10-211-1/+1
| | | | |
| * | | | Add whitelist of safe intrinsicsFrancesco Zardi2020-10-213-2/+98
| | | | |
* | | | | Update cratesJeremy Kolb2020-10-203-3/+3
| | | | | | | | | | | | | | | | | | | | This brings in a number of new dependencies though.
* | | | | add completions for clippy lint in attributesBenjamin Coenen2020-10-204-132/+10
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Benjamin Coenen <[email protected]>
* | | | | Merge #6256bors[bot]2020-10-203-0/+160
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6256: Assist: replace string with char r=bnjjj a=bnjjj close #6252 Co-authored-by: Benjamin Coenen <[email protected]> Co-authored-by: Coenen Benjamin <[email protected]>
| * | | | | Update crates/assists/src/handlers/replace_string_with_char.rsCoenen Benjamin2020-10-201-1/+1
| | | | | | | | | | | | | | | | | | Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | | Assist: replace string with charBenjamin Coenen2020-10-202-8/+39
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Benjamin Coenen <[email protected]>
| * | | | | replace_string_with_char #6252Benjamin Coenen2020-10-162-0/+129
| | |_|_|/ | |/| | | | | | | | | | | | | Signed-off-by: Benjamin Coenen <[email protected]>
* | | | | Merge #6172bors[bot]2020-10-206-24/+1090
|\ \ \ \ \ | |_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6172: Add qualify path assist r=matklad a=Veykril This implements a `qualify_path` assist which works quite similar to the `auto_import` assist but instead of adding imports to the file it well, qualifies the path. This PR also moves out the `AutoImportAssets` struct and functions from `auto_import` into a utils submodule as most of this is now shared between `auto_import` and `qualify_path`. Changes made to `AutoImportAssets` are solely in its `search_for_imports` function which now takes a prefixed parameter to discern between using `find_use_path_prefixed` and `find_use_path` as the former is the required behavior by `auto_import` and the latter by this assist. For missing imported traits instead of importing this will qualify the path with a trait cast as in: ```rust test_mod::TestStruct::TEST_CONST<|> ``` becomes ```rust <test_mod::TestStruct as test_mod::TestTrait>::TEST_CONST ``` and for trait methods ideally it would do the following: ```rust let test_struct = test_mod::TestStruct {}; test_struct.test_meth<|>od() ``` becomes ```rust let test_struct = test_mod::TestStruct {}; test_mod::TestTrait::test_method(&test_struct) ``` Fixes #4124. Co-authored-by: Lukas Wirth <[email protected]>
| * | | | De-duplicate `add_group` callsite in qualify_pathLukas Wirth2020-10-161-121/+108
| | | | |
| * | | | Properly qualify trait methods in qualify_path assistLukas Wirth2020-10-155-70/+118
| | | | |
| * | | | Add mark tests to qualify_path assistLukas Wirth2020-10-141-0/+9
| | | | |
| * | | | Add qualify path assistLukas Wirth2020-10-142-0/+1022
| | | | |
* | | | | Merge #6299bors[bot]2020-10-208-67/+141
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6299: Diagnose items that are #[cfg]d out r=jonas-schievink a=jonas-schievink This emits a hint-level diagnostic with `Unnecessary` tag to "gray out" any items whose `#[cfg]` attributes remove the item before name resolution. Co-authored-by: Jonas Schievink <[email protected]>
| * | | | | Fixup botched renameJonas Schievink2020-10-201-1/+1
| | | | | |
| * | | | | More detailed messageJonas Schievink2020-10-201-1/+1
| | | | | |
| * | | | | Rename UnconfiguredCode -> InactiveCodeJonas Schievink2020-10-203-5/+5
| | | | | |
| * | | | | Add a (hint) diagnostic for unconfigured itemsJonas Schievink2020-10-206-3/+86
| | | | | |
| * | | | | Simplify diagnostic construction, add unused fieldJonas Schievink2020-10-203-64/+55
| | | | | |
* | | | | | Don't rely on display names in inlay_hintsAleksey Kladov2020-10-204-19/+29
|/ / / / /
* | | | | Support Display name in project.jsonAleksey Kladov2020-10-202-3/+7
| | | | |
* | | | | More type safety around namesAleksey Kladov2020-10-206-19/+33
| | | | |
* | | | | Introduce CrateDisplayNameAleksey Kladov2020-10-201-1/+23
| | | | |
* | | | | Rename declaration_name -> display_nameAleksey Kladov2020-10-2011-35/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Declaration names sounds like a name of declaration -- something you can use for analysis. It empathically isn't, and is just a label displayed in various UI. It's important not to confuse the two, least we accidentally mix semantics with UI (I believe, there's already a case of this in the FamousDefs at least).
* | | | | Merge #6294bors[bot]2020-10-202-0/+28
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6294: Add a hacky remidy for #6038 r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
| * | | | | Add a hacky remidy for #6038Aleksey Kladov2020-10-202-0/+28
| | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | The proper fix I think is: * move rust-lang/rust library crates to a separate workspace * when packaging rust-src component, vendor sources of external deps
* / | | | Add descriptions for diagnostics parseable by xtaskIgor Aleksanov2020-10-192-0/+64
|/ / / /
* | | | Minor, rename featureAleksey Kladov2020-10-191-1/+1
| | | |
* | | | Try to fix publishingAleksey Kladov2020-10-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This errro specifically: Updating crates.io index error: failed to select a version for the requirement `ra_ap_stdx = "^0.0.0"` candidate versions found which didn't match: 0.0.20 location searched: /home/runner/work/rust-analyzer/rust-analyzer/crates/stdx required by package `ra_ap_completion v0.0.20 (/home/runner/work/rust-analyzer/rust-analyzer/crates/completion)` error: unable to update Cargo.lock Error: Process completed with exit code 1.
* | | | Change visibility works for type aliasesAleksey Kladov2020-10-182-5/+19
| | | |
* | | | Extract call_info and completion into separate cratesIgor Aleksanov2020-10-1832-226/+300
| | | |
* | | | update depsAleksey Kladov2020-10-181-1/+1
| | | |