]> git.lizzy.rs Git - rust.git/log
rust.git
2 years agoMerge #10902
bors[bot] [Sun, 5 Dec 2021 10:52:54 +0000 (10:52 +0000)]
Merge #10902

10902: Handle multiple cargo check quick fix spans r=Veykril a=brandondong

Resolves https://github.com/rust-analyzer/rust-analyzer/issues/10705.

**Cause:**
- For a cargo check diagnostic with multiple spans, only a single quick fix action would be created at the location of `spans[0]`. Additionally, the hover window details would only show the location of `spans[0]` next to the message.

**Fix:**
- Allow cargo check quick fix actions to be triggerable from multiple selection ranges. Specifically, if the selection intersects with any of the replacement spans, the quick fix action is shown.
- No change in behavior for the hover window details. It's pretty minor and I think showing multiple locations next to the message may be more confusing anyways.

Co-authored-by: Brandon <brandondong604@hotmail.com>
2 years agoUpdate expected test results
Brandon [Sun, 5 Dec 2021 05:26:07 +0000 (21:26 -0800)]
Update expected test results

2 years agoHandle multiple cargo check quick fix spans
Brandon [Sun, 5 Dec 2021 04:59:26 +0000 (20:59 -0800)]
Handle multiple cargo check quick fix spans

2 years agoRefactor away unnecessary Vec
Brandon [Sun, 5 Dec 2021 03:59:05 +0000 (19:59 -0800)]
Refactor away unnecessary Vec

2 years agoMerge #10930
bors[bot] [Sat, 4 Dec 2021 18:08:11 +0000 (18:08 +0000)]
Merge #10930

10930: fix: Fix self keyword not being tagged as such in highlighting properly r=Veykril a=Veykril

Fixes https://github.com/rust-analyzer/rust-analyzer/issues/10575
bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agofix: Fix self keyword not being tagged as such in highlighting properly
Lukas Wirth [Sat, 4 Dec 2021 18:07:18 +0000 (19:07 +0100)]
fix: Fix self keyword not being tagged as such in highlighting properly

2 years agoMerge #10929
bors[bot] [Sat, 4 Dec 2021 17:33:16 +0000 (17:33 +0000)]
Merge #10929

10929: internal: Split up macro/attribute semantic tokens a bit more r=Veykril a=Veykril

Fixes https://github.com/rust-analyzer/rust-analyzer/issues/9172

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agoUpdate semantic token docs
Lukas Wirth [Sat, 4 Dec 2021 17:23:25 +0000 (18:23 +0100)]
Update semantic token docs

2 years agoIntroduce SymbolKind::Derive
Lukas Wirth [Sat, 4 Dec 2021 17:18:09 +0000 (18:18 +0100)]
Introduce SymbolKind::Derive

2 years agoIntroduce SymbolKind::Attribute
Lukas Wirth [Sat, 4 Dec 2021 17:01:22 +0000 (18:01 +0100)]
Introduce SymbolKind::Attribute

2 years agoMerge #10928
bors[bot] [Sat, 4 Dec 2021 13:21:40 +0000 (13:21 +0000)]
Merge #10928

10928: minor: Bump deps r=lnicola a=lnicola

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoBump pulldown-cmark-to-cmark
Laurențiu Nicola [Sat, 4 Dec 2021 13:21:04 +0000 (15:21 +0200)]
Bump pulldown-cmark-to-cmark

2 years agoBump miow
Laurențiu Nicola [Sat, 4 Dec 2021 13:17:30 +0000 (15:17 +0200)]
Bump miow

2 years agoBump countme
Laurențiu Nicola [Sat, 4 Dec 2021 13:14:31 +0000 (15:14 +0200)]
Bump countme

2 years agoBump chalk
Laurențiu Nicola [Sat, 4 Dec 2021 13:08:43 +0000 (15:08 +0200)]
Bump chalk

2 years agoBump most deps
Laurențiu Nicola [Sat, 4 Dec 2021 12:54:54 +0000 (14:54 +0200)]
Bump most deps

2 years agoMerge #10927
bors[bot] [Sat, 4 Dec 2021 12:37:19 +0000 (12:37 +0000)]
Merge #10927

10927: minor: bump the rest of the npm deps r=lnicola a=lnicola

bors r+

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoBump rest of the npm deps
Laurențiu Nicola [Sat, 4 Dec 2021 12:28:48 +0000 (14:28 +0200)]
Bump rest of the npm deps

2 years agoBump node-fetch
Laurențiu Nicola [Fri, 3 Dec 2021 19:50:17 +0000 (21:50 +0200)]
Bump node-fetch

2 years agoBump vsce
Laurențiu Nicola [Fri, 3 Dec 2021 19:47:04 +0000 (21:47 +0200)]
Bump vsce

2 years agoBump eslint
Laurențiu Nicola [Fri, 3 Dec 2021 19:37:17 +0000 (21:37 +0200)]
Bump eslint

2 years agoBump engine in lockfile
Laurențiu Nicola [Fri, 3 Dec 2021 19:37:04 +0000 (21:37 +0200)]
Bump engine in lockfile

2 years agoMerge #10925
bors[bot] [Sat, 4 Dec 2021 12:17:29 +0000 (12:17 +0000)]
Merge #10925

10925: minor: Simplify `.vscodeignore` r=lnicola a=lnicola

The quadruple negation we used to have here was quite confusing:

```gitignore
**
!out
out/**
!out/src
```

Let's ignore everything and cherry-pick what we want to include.

~~And also include the extension sourcemap, just in case someone wants to debug the extension.~~

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoSimplify `.vscodeignore`
Laurențiu Nicola [Sat, 4 Dec 2021 10:34:13 +0000 (12:34 +0200)]
Simplify `.vscodeignore`

2 years agoMerge #10924
bors[bot] [Sat, 4 Dec 2021 11:44:27 +0000 (11:44 +0000)]
Merge #10924

10924: minor: Add LICENSE file to make vsce happy r=lnicola a=lnicola

Newer `vsce` versions error out if a `LICENSE` file is missing, even if the license is specified in `package.json`. Concatenate the two licenses we use and add a file with that to make a future `vsce` upgrade easier.

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoMerge #10926
bors[bot] [Sat, 4 Dec 2021 10:46:05 +0000 (10:46 +0000)]
Merge #10926

10926: minor: Bump Node to 14 in release workflow r=lnicola a=lnicola

bors r+

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoBump Node to 14 in release workflow
Laurențiu Nicola [Sat, 4 Dec 2021 10:45:08 +0000 (12:45 +0200)]
Bump Node to 14 in release workflow

2 years agoAdd LICENSE file to make vsce happy
Laurențiu Nicola [Sat, 4 Dec 2021 10:17:35 +0000 (12:17 +0200)]
Add LICENSE file to make vsce happy

2 years agoMerge #10921
bors[bot] [Fri, 3 Dec 2021 23:52:28 +0000 (23:52 +0000)]
Merge #10921

10921: minor: Update list of safe intrinsics r=Veykril a=Veykril

Closes https://github.com/rust-analyzer/rust-analyzer/issues/4798
bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agominor: Update list of safe intrinsics
Lukas Wirth [Fri, 3 Dec 2021 23:51:50 +0000 (00:51 +0100)]
minor: Update list of safe intrinsics

2 years agoMerge #10920
bors[bot] [Fri, 3 Dec 2021 23:27:50 +0000 (23:27 +0000)]
Merge #10920

10920: minor: Shorten spans of mismatched_arg_count diag r=Veykril a=Veykril

Fixes #5289
bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agominor: Shorten spans of mismatched_arg_count diag
Lukas Wirth [Fri, 3 Dec 2021 23:16:47 +0000 (00:16 +0100)]
minor: Shorten spans of mismatched_arg_count diag

2 years agoMerge #10919
bors[bot] [Fri, 3 Dec 2021 22:53:32 +0000 (22:53 +0000)]
Merge #10919

10919: internal: Define missing semantic token hierarchies in package.json r=Veykril a=Veykril

Closes https://github.com/rust-analyzer/rust-analyzer/issues/10077
bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agoAdd some more semantic token to textmate grammar mapping
Lukas Wirth [Fri, 3 Dec 2021 21:16:57 +0000 (22:16 +0100)]
Add some more semantic token to textmate grammar mapping

2 years agoDefine missing semantic token hierarchies in package.json
Lukas Wirth [Fri, 3 Dec 2021 20:59:34 +0000 (21:59 +0100)]
Define missing semantic token hierarchies in package.json

2 years agoMerge #10916
bors[bot] [Fri, 3 Dec 2021 20:21:55 +0000 (20:21 +0000)]
Merge #10916

10916: feat: ide: Convert while let to loop r=Veykril a=rainy-me

close #10901

Co-authored-by: rainy-me <github@yue.coffee>
2 years agofix: defer condition construction
rainy-me [Fri, 3 Dec 2021 19:50:06 +0000 (04:50 +0900)]
fix: defer condition construction

2 years agoMerge #10915
bors[bot] [Fri, 3 Dec 2021 19:28:36 +0000 (19:28 +0000)]
Merge #10915

10915: feat: Resolve builtin-attr and tools in ide layer r=Veykril a=Veykril

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2 years agoImprove hover message for inert attributes
Lukas Wirth [Fri, 3 Dec 2021 19:28:15 +0000 (20:28 +0100)]
Improve hover message for inert attributes

2 years agoMerge #10917
bors[bot] [Fri, 3 Dec 2021 18:54:52 +0000 (18:54 +0000)]
Merge #10917

10917: minor: Bump some npm deps r=lnicola a=lnicola

bors r+

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoBump engine
Laurențiu Nicola [Fri, 3 Dec 2021 18:52:41 +0000 (20:52 +0200)]
Bump engine

2 years agoBump esbuild
Laurențiu Nicola [Fri, 3 Dec 2021 18:52:29 +0000 (20:52 +0200)]
Bump esbuild

2 years agoBump typescript
Laurențiu Nicola [Fri, 3 Dec 2021 18:49:38 +0000 (20:49 +0200)]
Bump typescript

2 years agoBump @types/vscode
Laurențiu Nicola [Fri, 3 Dec 2021 18:48:15 +0000 (20:48 +0200)]
Bump @types/vscode

2 years agoBump eslint
Laurențiu Nicola [Fri, 3 Dec 2021 18:46:19 +0000 (20:46 +0200)]
Bump eslint

2 years agoBump vscode-test
Laurențiu Nicola [Fri, 3 Dec 2021 18:40:29 +0000 (20:40 +0200)]
Bump vscode-test

2 years agoBump tslib
Laurențiu Nicola [Fri, 3 Dec 2021 18:35:22 +0000 (20:35 +0200)]
Bump tslib

2 years agoBump node-fetch and @types/node-fetch
Laurențiu Nicola [Fri, 3 Dec 2021 18:33:14 +0000 (20:33 +0200)]
Bump node-fetch and @types/node-fetch

2 years agoBump @types/node
Laurențiu Nicola [Fri, 3 Dec 2021 18:30:26 +0000 (20:30 +0200)]
Bump @types/node

2 years agoBump d3
Laurențiu Nicola [Fri, 3 Dec 2021 18:29:30 +0000 (20:29 +0200)]
Bump d3

2 years agofeat: handle while let to loop
rainy-me [Fri, 3 Dec 2021 18:19:19 +0000 (03:19 +0900)]
feat: handle while let to loop

2 years agoRename things: Tool -> ToolModule
Lukas Wirth [Fri, 3 Dec 2021 16:15:19 +0000 (17:15 +0100)]
Rename things: Tool -> ToolModule

2 years agoBasic hover for builtin-attr and tool modules
Lukas Wirth [Fri, 3 Dec 2021 16:10:56 +0000 (17:10 +0100)]
Basic hover for builtin-attr and tool modules

2 years agoSimplify
Lukas Wirth [Fri, 3 Dec 2021 16:07:06 +0000 (17:07 +0100)]
Simplify

2 years agoRemove syntax highlighting hack for builtin attrs
Lukas Wirth [Fri, 3 Dec 2021 15:53:30 +0000 (16:53 +0100)]
Remove syntax highlighting hack for builtin attrs

2 years agofeat: Resolve builtin-attr and tools in ide layer
Lukas Wirth [Fri, 3 Dec 2021 15:32:14 +0000 (16:32 +0100)]
feat: Resolve builtin-attr and tools in ide layer

2 years agoMerge #10906
bors[bot] [Fri, 3 Dec 2021 10:42:39 +0000 (10:42 +0000)]
Merge #10906

10906: [first contributation] fix: `add return type` assit works when there's missing whitespace r=Veykril a=izik1

I feel like the way I handled whitespace here isn't... Right? Maybe it should be folded into `InsertOrReplace::Insert`

Also, sorry about the commit name, I am _not_ good at writing user facing commit messages

Also sorry about the test names, could be clearer I feel

Co-authored-by: Skyler Rain Ross <orangesnowfox@gmail.com>
2 years agorefactor(assist/add_return_type): avoid threading `needs_whitespace`
Skyler Rain Ross [Thu, 2 Dec 2021 18:46:07 +0000 (10:46 -0800)]
refactor(assist/add_return_type): avoid threading `needs_whitespace`

2 years agoMerge #10903
bors[bot] [Thu, 2 Dec 2021 17:37:56 +0000 (17:37 +0000)]
Merge #10903

10903: internal: Replace `mocha` with a custom test runner r=Aloso a=lnicola

Closes #10723

r? `@Aloso`

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agofix: add return type works when there's missing whitespace
Skyler Rain Ross [Thu, 2 Dec 2021 17:25:17 +0000 (09:25 -0800)]
fix: add return type works when there's missing whitespace

2 years agoMerge #10905
bors[bot] [Thu, 2 Dec 2021 13:47:03 +0000 (13:47 +0000)]
Merge #10905

10905: minor: Fix proxyStrictSSL check r=lnicola a=lnicola

bors r+

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoFix proxyStrictSSL check
Laurențiu Nicola [Thu, 2 Dec 2021 13:46:23 +0000 (15:46 +0200)]
Fix proxyStrictSSL check

2 years agoMerge #10891
bors[bot] [Thu, 2 Dec 2021 11:21:59 +0000 (11:21 +0000)]
Merge #10891

10891: fix: emit trait names in moniker identifier r=Veykril a=tjdevries

Hi,

Not sure if this is the best fix for the problem, but I noticed that functions that part of a trait are not namespaced with the trait name, so this could lead to problems if you had a function and a trait-function both defined in the same module.

Thanks!

TJ

Co-authored-by: TJ DeVries <devries.timothyj@gmail.com>
2 years agoReplace mocha with a custom test runner
Laurențiu Nicola [Thu, 2 Dec 2021 06:20:10 +0000 (08:20 +0200)]
Replace mocha with a custom test runner

2 years agofixup: include more information for impls
TJ DeVries [Thu, 2 Dec 2021 05:04:03 +0000 (00:04 -0500)]
fixup: include more information for impls

2 years agofixup: properly handle all associated items
TJ DeVries [Wed, 1 Dec 2021 16:43:52 +0000 (11:43 -0500)]
fixup: properly handle all associated items

2 years agoMerge #10899
bors[bot] [Wed, 1 Dec 2021 12:36:17 +0000 (12:36 +0000)]
Merge #10899

10899: ide: hack to make self not unresolved reference in async trait wrapped impl's r=Veykril a=jhgg

fixes #10708

this is a bit hacky, but it "works".

i'm not sure how to even write a test for this though, but i've confirmed it works via manual testing...

Co-authored-by: Jake Heinz <jh@discordapp.com>
2 years agoadd a fixme:
Jake Heinz [Wed, 1 Dec 2021 12:26:27 +0000 (12:26 +0000)]
add a fixme:

2 years agosimplify
Jake Heinz [Wed, 1 Dec 2021 12:25:08 +0000 (12:25 +0000)]
simplify

2 years agoide: hack to make self not unresolved reference in async trait wrapped impl's
Jake Heinz [Wed, 1 Dec 2021 12:16:43 +0000 (12:16 +0000)]
ide: hack to make self not unresolved reference in async trait wrapped impl's

2 years agoMerge #10897
bors[bot] [Wed, 1 Dec 2021 11:28:17 +0000 (11:28 +0000)]
Merge #10897

10897: internal: Try to fix Code tests r=lnicola a=lnicola

It looks like `--noEmit` broke our unit tests:

![image](https://user-images.githubusercontent.com/308347/144217192-a8133a6b-880f-4852-846b-b45527485336.png)

r? `@ChayimFriedman2`

I suppose we might still:

 - compile stuff twice
 - not detect failing tests on CI (since we didn't notice this)

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoBump to Node 14
Laurențiu Nicola [Wed, 1 Dec 2021 11:09:43 +0000 (13:09 +0200)]
Bump to Node 14

2 years agoUse xvfb-run directly
Laurențiu Nicola [Wed, 1 Dec 2021 11:07:12 +0000 (13:07 +0200)]
Use xvfb-run directly

2 years agoBump xvfb-action to fix Code tests
Laurențiu Nicola [Wed, 1 Dec 2021 10:52:24 +0000 (12:52 +0200)]
Bump xvfb-action to fix Code tests

2 years agoMerge #10896
bors[bot] [Wed, 1 Dec 2021 10:28:49 +0000 (10:28 +0000)]
Merge #10896

10896: hir: resolve assoc trait type in path r=jhgg a=jhgg

fixes #9802

- [ ] write tests, maybe, if this is even a good fix...

Co-authored-by: Jake Heinz <jh@discordapp.com>
2 years agoadd test
Jake Heinz [Wed, 1 Dec 2021 10:28:18 +0000 (10:28 +0000)]
add test

2 years agoTry to fix Code tests
Laurențiu Nicola [Wed, 1 Dec 2021 10:22:34 +0000 (12:22 +0200)]
Try to fix Code tests

2 years agosimplify??
Jake Heinz [Wed, 1 Dec 2021 09:23:42 +0000 (09:23 +0000)]
simplify??

2 years agohir: resolve assoc trait type
Jake Heinz [Wed, 1 Dec 2021 08:44:30 +0000 (08:44 +0000)]
hir: resolve assoc trait type

2 years agofix: emit trait names in moniker identifier
TJ DeVries [Tue, 30 Nov 2021 16:16:11 +0000 (11:16 -0500)]
fix: emit trait names in moniker identifier

2 years agoMerge #10872
bors[bot] [Tue, 30 Nov 2021 14:07:39 +0000 (14:07 +0000)]
Merge #10872

10872: ide_db: build symbol index from crate def map r=Veykril a=jhgg

fixes #4842, #10764

Is this looking correct? :eyes:

- [x] build the symbol index based upon the CrateDefMap for the given crate in `crate_symbols`
   - [x] make it multi threaded again, and figure out how to cache each moduleid's symbol index in salsa.
   - [x] NavigationTarget for names in macros is wrong, need to figure out how to compute a text range in the original file id?
   - [x] cleanup some duped code
   - [x] collect macros from `ItemScope.declared_macros()` into symbol index.
        - [x] store declared macros in `ItemScope` so we can figure out where macros were defined for the index.
   - [x] do something about `SymbolIndex::for_files` - ideally it should use the new module symbol index stuff.
       - [x] delete `source_file_to_file_symbols` & co...
           - [x] figure out what to do about `library_symbols`
           - [x] maybe... speed up the new `library_symbols` - the new impl is probably much slower, and definitely much less parallel. **deciding to do nothing here, we can optimize later if necerssary.**
   - [x] fix failing test: `navigation_target::tests::test_nav_for_symbol` - notably the crate def map doesn't seem to find declarations inside function.
       - [x] now a bunch of other tests are failing around auto_import & qualify_path handlers. :(
           - [x] need to assoc items in traits and impls

Co-authored-by: Jake Heinz <jh@discordapp.com>
2 years agosimpler way of grabbing module / trait name
Jake Heinz [Tue, 30 Nov 2021 08:24:07 +0000 (08:24 +0000)]
simpler way of grabbing module /  trait name

2 years agoremove one need for semantics
Jake Heinz [Tue, 30 Nov 2021 04:50:09 +0000 (04:50 +0000)]
remove one need for semantics

2 years agoconsts with inners??
Jake Heinz [Tue, 30 Nov 2021 03:21:17 +0000 (03:21 +0000)]
consts with inners??

2 years agopr feedbacks
Jake Heinz [Tue, 30 Nov 2021 03:09:38 +0000 (03:09 +0000)]
pr feedbacks

2 years agoMerge #10887
bors[bot] [Mon, 29 Nov 2021 22:03:04 +0000 (22:03 +0000)]
Merge #10887

10887: internal: Update bug report template to include version info r=Veykril a=jonas-schievink

Co-authored-by: Jonas Schievink <jonasschievink@gmail.com>
2 years agoUpdate bug report template to include version info
Jonas Schievink [Mon, 29 Nov 2021 21:35:16 +0000 (22:35 +0100)]
Update bug report template to include version info

2 years agoMerge #10871
bors[bot] [Mon, 29 Nov 2021 18:02:41 +0000 (18:02 +0000)]
Merge #10871

10871: Respect `http.proxyStrictSSL` r=lnicola a=lnicola

Closes #10866

Currently untested.

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2 years agoMerge #10841
bors[bot] [Mon, 29 Nov 2021 11:13:39 +0000 (11:13 +0000)]
Merge #10841

10841: Emit moniker in lsif r=Veykril a=HKalbasi

fix #10559

Co-authored-by: hkalbasi <hamidrezakalbasi@protonmail.com>
Co-authored-by: HKalbasi <45197576+HKalbasi@users.noreply.github.com>
2 years agotest the one thing this pr was trying to accomplish lol...
Jake Heinz [Mon, 29 Nov 2021 10:43:51 +0000 (10:43 +0000)]
test the one thing this pr was trying to accomplish lol...

2 years agoadd a test
Jake Heinz [Mon, 29 Nov 2021 10:36:22 +0000 (10:36 +0000)]
add a test

2 years agosome more cleanups
Jake Heinz [Mon, 29 Nov 2021 09:52:03 +0000 (09:52 +0000)]
some more cleanups

2 years agodo something with library_symbols
Jake Heinz [Mon, 29 Nov 2021 09:36:00 +0000 (09:36 +0000)]
do something with library_symbols

2 years agofix tests
hkalbasi [Mon, 29 Nov 2021 07:55:53 +0000 (11:25 +0330)]
fix tests

2 years agoremove duplicate data from CrateOrigin
hkalbasi [Mon, 29 Nov 2021 07:40:39 +0000 (11:10 +0330)]
remove duplicate data from CrateOrigin

2 years agosimplify work
Jake Heinz [Mon, 29 Nov 2021 07:17:18 +0000 (07:17 +0000)]
simplify work

2 years ago:broom:
Jake Heinz [Mon, 29 Nov 2021 05:42:46 +0000 (05:42 +0000)]
:broom:

2 years agocollect macro_rules! macros into macro declarations
Jake Heinz [Mon, 29 Nov 2021 05:28:22 +0000 (05:28 +0000)]
collect macro_rules! macros into macro declarations

2 years agocollect macros
Jake Heinz [Mon, 29 Nov 2021 05:22:30 +0000 (05:22 +0000)]
collect macros

2 years agocleanup the whole thing...
Jake Heinz [Mon, 29 Nov 2021 03:54:52 +0000 (03:54 +0000)]
cleanup the whole thing...