]>
git.lizzy.rs Git - rust.git/log
dependabot[bot] [Thu, 11 Jul 2019 23:44:16 +0000 (23:44 +0000)]
Bump lodash from 4.17.11 to 4.17.14 in /editors/code
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.11 to 4.17.14.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.11...4.17.14)
Signed-off-by: dependabot[bot] <support@github.com>
bors[bot] [Thu, 11 Jul 2019 09:13:10 +0000 (09:13 +0000)]
Merge #1520
1520: Ignore workspace/didChangeConfiguration notifications. r=matklad a=bolinfest
If the client happens to send a `workspace/didChangeConfiguration`
notification, it is nicer if rust-analyzer can just ignore it rather than
crash with an "unhandled notification" error.
Co-authored-by: Michael Bolin <bolinfest@gmail.com>
Michael Bolin [Thu, 11 Jul 2019 05:49:29 +0000 (22:49 -0700)]
Remove executeCommandProvider: apply_code_action.
This appears to have been introduced ages ago in
https://github.com/rust-analyzer/rust-analyzer/commit/
be742a587704f27f4e503c50f549aa9ec1527fcc
but has since been removed.
As it stands, it is problematic if multiple instances of the
rust-analyzer LSP are launched during the same VS Code session because
VS Code complains about multiple LSP servers trying to register the
same command.
Most LSP servers workaround this by parameterizing the command by the
process id. For example, this is where `rls` does this:
https://github.com/rust-lang/rls/blob/
ff0b9057c8f62bc4f8113d741e96c9587ef1a817 /rls/src/server/mod.rs#L413-L421
Though `apply_code_action` does not seems to be used, so it seems better
to delete it than to parameterize it.
Michael Bolin [Thu, 11 Jul 2019 03:44:23 +0000 (20:44 -0700)]
Ignore workspace/didChangeConfiguration notifications.
bors[bot] [Wed, 10 Jul 2019 19:06:44 +0000 (19:06 +0000)]
Merge #1519
1519: Move whitespace manipulation inside AstEditor r=matklad a=viorina
Co-authored-by: Ekaterina Babshukova <ekaterina.babshukova@yandex.ru>
Ekaterina Babshukova [Wed, 10 Jul 2019 18:53:44 +0000 (21:53 +0300)]
move whitespace manipulation inside AstEditor
bors[bot] [Wed, 10 Jul 2019 16:59:44 +0000 (16:59 +0000)]
Merge #1518
1518: Remove a fixme r=matklad a=killercup
Just saw the new release of SmolStr and was reminded of this FIXME I added :)
Co-authored-by: Pascal Hertleif <pascal@technocreatives.com>
Pascal Hertleif [Wed, 10 Jul 2019 15:05:39 +0000 (17:05 +0200)]
Make clippy a bit happier
Random drive-by fix. I honestly blame rust-analyzer itself on this,
because I set its watch mode to use `cargo clippy` :shrug:
Pascal Hertleif [Wed, 10 Jul 2019 15:04:38 +0000 (17:04 +0200)]
Resolve a FIXME
Now that we are using a newer smol_str release this can be simplified :)
Aleksey Kladov [Tue, 9 Jul 2019 08:13:15 +0000 (11:13 +0300)]
fix profile name
bors[bot] [Tue, 9 Jul 2019 07:50:18 +0000 (07:50 +0000)]
Merge #1515
1515: Trait environment r=matklad a=flodiebold
This adds the environment, i.e. the set of `where` clauses in scope, when solving trait goals. That means that e.g. in
```rust
fn foo<T: SomeTrait>(t: T) {}
```
, we are able to complete methods of `SomeTrait` on the `t`. This affects the trait APIs quite a bit (since every method that needs to be able to solve for some trait needs to get this environment somehow), so I thought I'd do it rather sooner than later ;)
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
bors[bot] [Tue, 9 Jul 2019 00:41:03 +0000 (00:41 +0000)]
Merge #1512
1512: Infer ? operator r=unrealhoang a=unrealhoang
Logical continuation of https://github.com/rust-analyzer/rust-analyzer/pull/1501
cc https://github.com/rust-analyzer/rust-analyzer/issues/1426
Co-authored-by: Unreal Hoang <unrealhoang@gmail.com>
Unreal Hoang [Mon, 8 Jul 2019 16:01:07 +0000 (01:01 +0900)]
beautify tests
Florian Diebold [Mon, 8 Jul 2019 19:43:52 +0000 (21:43 +0200)]
Unify `normalize` and `implements` to simplify code
Florian Diebold [Sun, 7 Jul 2019 16:14:56 +0000 (18:14 +0200)]
Use environment for associated type normalization as well
Florian Diebold [Sat, 29 Jun 2019 17:14:52 +0000 (19:14 +0200)]
Start handling environment in trait resolution
I.e. if we are inside a function with some where clauses, we assume these where
clauses hold.
Florian Diebold [Sat, 29 Jun 2019 15:40:00 +0000 (17:40 +0200)]
Refactor a bit & introduce Environment struct
bors[bot] [Mon, 8 Jul 2019 19:18:49 +0000 (19:18 +0000)]
Merge #1514
1514: Better completions for floating point primitive types r=flodiebold a=marcogroppo
After #1499 completions for (some of) the inherent methods of `f32` and `f64` are now working.
Unfortunately during method resolution we were only looking for the `f32` and `f64` language items defined in `libcore` and we were ignoring the methods defined in `libstd`.
This PR fixes this issue.
Co-authored-by: Marco Groppo <marco.groppo@gmail.com>
Marco Groppo [Mon, 8 Jul 2019 18:37:29 +0000 (20:37 +0200)]
Look for the fXX_runtime lang items during method resolution.
Unreal Hoang [Mon, 8 Jul 2019 15:45:12 +0000 (00:45 +0900)]
use namespaced consts for KnownName
bors[bot] [Mon, 8 Jul 2019 15:44:33 +0000 (15:44 +0000)]
Merge #1513
1513: Remove unused dependencies r=matklad a=sinkuu
Co-authored-by: Shotaro Yamada <sinkuu@sinkuu.xyz>
Shotaro Yamada [Mon, 8 Jul 2019 15:28:00 +0000 (00:28 +0900)]
Remove unused dependencies
Unreal Hoang [Mon, 8 Jul 2019 15:02:15 +0000 (00:02 +0900)]
projection over std::ops::Try::Ok to infer try/?
bors[bot] [Mon, 8 Jul 2019 12:32:16 +0000 (12:32 +0000)]
Merge #1511
1511: Send old-style responsed to goto definition unless the client explicitelly opts in r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Mon, 8 Jul 2019 11:09:38 +0000 (14:09 +0300)]
don't send LocationLink unless the client opts-in
closes #1474
Aleksey Kladov [Mon, 8 Jul 2019 10:47:02 +0000 (13:47 +0300)]
simplify
Aleksey Kladov [Mon, 8 Jul 2019 10:39:16 +0000 (13:39 +0300)]
add try_conv_with_to_vec
bors[bot] [Mon, 8 Jul 2019 09:55:23 +0000 (09:55 +0000)]
Merge #1504
1504: Simplify LSP handlers r=matklad a=kjeremy
Takes advantage of protocol inheritance via composition and simplifies some responses via the `From`/`Into` traits.
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
bors[bot] [Mon, 8 Jul 2019 08:29:19 +0000 (08:29 +0000)]
Merge #1507
1507: Constify KnownName's r=matklad a=mominul
Closes #1503
Co-authored-by: Muhammad Mominul Huque <mominul2082@gmail.com>
Muhammad Mominul Huque [Sun, 7 Jul 2019 22:09:35 +0000 (04:09 +0600)]
cargo format
bors[bot] [Sun, 7 Jul 2019 21:45:19 +0000 (21:45 +0000)]
Merge #1506
1506: Update memchr r=kjeremy a=kjeremy
New release has some performance improvements.
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Sun, 7 Jul 2019 21:42:24 +0000 (17:42 -0400)]
Update memchr
Muhammad Mominul Huque [Sun, 7 Jul 2019 21:29:38 +0000 (03:29 +0600)]
Constify KnownName's
Jeremy Kolb [Sun, 7 Jul 2019 21:28:21 +0000 (17:28 -0400)]
Simplify responses by using into()
Jeremy Kolb [Sun, 7 Jul 2019 18:13:13 +0000 (14:13 -0400)]
use flatten branch of lsp-types
bors[bot] [Sun, 7 Jul 2019 15:20:09 +0000 (15:20 +0000)]
Merge #1501
1501: Infer for loop variable r=flodiebold a=unrealhoang
My take on https://github.com/rust-analyzer/rust-analyzer/issues/1425
Co-authored-by: Unreal Hoang <unrealhoang@gmail.com>
bors[bot] [Sun, 7 Jul 2019 13:48:58 +0000 (13:48 +0000)]
Merge #1499
1499: processing attribute #[path] of module r=matklad a=andreevlex
support two cases
- simple name file `foo.rs`
- declaration in mod.rs
#1211
Co-authored-by: Alexander Andreev <andreevlex.as@gmail.com>
Unreal Hoang [Sun, 7 Jul 2019 07:31:09 +0000 (16:31 +0900)]
add projection to infer for loop variable
Alexander Andreev [Sun, 7 Jul 2019 13:06:54 +0000 (16:06 +0300)]
Moved module resolution test in mods.rs
bors[bot] [Sun, 7 Jul 2019 11:24:35 +0000 (11:24 +0000)]
Merge #1502
1502: Use inline snapshots in compelte_postfix r=matklad a=funkill
Relates to #1127
Co-authored-by: funkill2 <funkill2@gmail.com>
funkill2 [Sun, 7 Jul 2019 10:52:16 +0000 (13:52 +0300)]
inline snapshot in complete_postfix
Alexander Andreev [Sat, 6 Jul 2019 18:54:21 +0000 (21:54 +0300)]
Added support attribute path in resolusion module fn
bors[bot] [Sat, 6 Jul 2019 17:50:03 +0000 (17:50 +0000)]
Merge #1497
1497: bump regex r=kjeremy a=kjeremy
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Sat, 6 Jul 2019 17:48:11 +0000 (13:48 -0400)]
bump regex
bors[bot] [Sat, 6 Jul 2019 16:28:42 +0000 (16:28 +0000)]
Merge #1496
1496: Add trait obligations for where clauses when calling functions/methods r=matklad a=flodiebold
E.g. if we call `foo<T: Into<u32>>(x)`, that adds an obligation that `x: Into<u32>`, etc., which sometimes allows type inference to make further progress.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
Florian Diebold [Sat, 6 Jul 2019 15:43:13 +0000 (17:43 +0200)]
Make EnumVariant a GenericDef and simplify some code
Florian Diebold [Sat, 6 Jul 2019 14:41:04 +0000 (16:41 +0200)]
Add trait obligations for where clauses when calling functions/methods
E.g. if we call `foo<T: Into<u32>>(x)`, that adds an obligation that `x:
Into<u32>`, etc.
Alexander Andreev [Sat, 6 Jul 2019 11:04:56 +0000 (14:04 +0300)]
Added extract path attribute for current module
#1211
Aleksey Kladov [Sat, 6 Jul 2019 05:33:19 +0000 (08:33 +0300)]
Create FUNDING.yml
bors[bot] [Fri, 5 Jul 2019 16:43:23 +0000 (16:43 +0000)]
Merge #1495
1495: use correct file for diagnostics r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Fri, 5 Jul 2019 16:40:02 +0000 (19:40 +0300)]
use correct file for diagnostics
closes #1475
bors[bot] [Fri, 5 Jul 2019 16:30:38 +0000 (16:30 +0000)]
Merge #1494
1494: properly restrict diagnostics to a single file r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Fri, 5 Jul 2019 16:27:20 +0000 (19:27 +0300)]
properly restrict diagnostics to a single file
bors[bot] [Fri, 5 Jul 2019 16:07:11 +0000 (16:07 +0000)]
Merge #1493
1493: Clippy trivially_copy_pass_by_ref r=matklad a=kjeremy
Clippy says that this is more efficient.
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Fri, 5 Jul 2019 16:02:32 +0000 (12:02 -0400)]
Clippy trivially_copy_pass_by_ref
bors[bot] [Fri, 5 Jul 2019 14:19:12 +0000 (14:19 +0000)]
Merge #1491
1491: More clippy r=matklad a=kjeremy
A few more clippy changes.
I'm a little unsure of the second commit. It's the trivially_copy_pass_by_ref lint and there are a number of places in the code we could use it if it makes sense.
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Fri, 5 Jul 2019 14:18:01 +0000 (10:18 -0400)]
readability
bors[bot] [Fri, 5 Jul 2019 06:41:09 +0000 (06:41 +0000)]
Merge #1492
1492: Fix clippy::redundant_clone r=matklad a=sinkuu
Co-authored-by: Shotaro Yamada <sinkuu@sinkuu.xyz>
Shotaro Yamada [Fri, 5 Jul 2019 03:41:53 +0000 (12:41 +0900)]
Fix clippy::redundant_clone
Jeremy Kolb [Fri, 5 Jul 2019 03:01:40 +0000 (23:01 -0400)]
&self -> self
https://rust-lang.github.io/rust-clippy/master/index.html#trivially_copy_pass_by_ref
Jeremy Kolb [Fri, 5 Jul 2019 02:59:28 +0000 (22:59 -0400)]
Clippy changes
bors[bot] [Thu, 4 Jul 2019 23:31:53 +0000 (23:31 +0000)]
Merge #1488
1488: Symplify by using into() r=kjeremy a=kjeremy
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Thu, 4 Jul 2019 23:31:06 +0000 (19:31 -0400)]
Formatting again
Jeremy Kolb [Thu, 4 Jul 2019 22:04:46 +0000 (18:04 -0400)]
Symplify by using into()
bors[bot] [Thu, 4 Jul 2019 22:10:47 +0000 (22:10 +0000)]
Merge #1487
1487: cargo update run r=matklad a=kjeremy
Might as well
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
bors[bot] [Thu, 4 Jul 2019 21:56:36 +0000 (21:56 +0000)]
Merge #1482
1482: Some clippy fixes for 1.36 r=kjeremy a=kjeremy
Some clippy fixes now that 1.36 is released. ~~Plus the requisite format run (I can rebase after #1481 is merged to make this cleaner) .~~
The change from `map(|it| *it)` to `copied()` changes the minimum rust stable to 1.36.
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Thu, 4 Jul 2019 21:52:22 +0000 (17:52 -0400)]
cargo update run
Jeremy Kolb [Thu, 4 Jul 2019 21:43:19 +0000 (17:43 -0400)]
Formatting
Jeremy Kolb [Thu, 4 Jul 2019 17:26:44 +0000 (13:26 -0400)]
Some clippy fixes for 1.36
bors[bot] [Thu, 4 Jul 2019 21:17:11 +0000 (21:17 +0000)]
Merge #1484
1484: Update to lsp-types 0.58.0 r=matklad a=kjeremy
Fixes CodeActionResponse
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
Jeremy Kolb [Thu, 4 Jul 2019 20:58:52 +0000 (16:58 -0400)]
Fix formatting
Jeremy Kolb [Thu, 4 Jul 2019 20:52:29 +0000 (16:52 -0400)]
Change default()
Jeremy Kolb [Thu, 4 Jul 2019 18:57:14 +0000 (14:57 -0400)]
Update to lsp-types 0.58.0
bors[bot] [Thu, 4 Jul 2019 20:32:52 +0000 (20:32 +0000)]
Merge #1485
1485: rand 0.7.0 r=matklad a=kjeremy
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
bors[bot] [Thu, 4 Jul 2019 20:09:32 +0000 (20:09 +0000)]
Merge #1486
1486: allow rustfmt to reorder imports r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Thu, 4 Jul 2019 20:05:17 +0000 (23:05 +0300)]
allow rustfmt to reorder imports
This wasn't a right decision in the first place, the feature flag was
broken in the last rustfmt release, and syntax highlighting of imports
is more important anyway
Jeremy Kolb [Thu, 4 Jul 2019 19:16:06 +0000 (15:16 -0400)]
rand 0.7.0
bors[bot] [Wed, 3 Jul 2019 19:29:21 +0000 (19:29 +0000)]
Merge #1478
1478: [WIP] Added resolve submodules with raw name r=matklad a=andreevlex
#1211
Co-authored-by: Alexander Andreev <andreevlex.as@gmail.com>
Alexander Andreev [Wed, 3 Jul 2019 19:17:43 +0000 (22:17 +0300)]
Fixed request changes
Alexander Andreev [Wed, 3 Jul 2019 19:01:41 +0000 (22:01 +0300)]
Move resolve raw name in name.rs
Added test for check module resolution with raw name
bors[bot] [Wed, 3 Jul 2019 15:48:14 +0000 (15:48 +0000)]
Merge #1476
1476: Extend add_impl_members to constants and types r=matklad a=viorina
Co-authored-by: Ekaterina Babshukova <ekaterina.babshukova@yandex.ru>
Alexander Andreev [Wed, 3 Jul 2019 14:37:56 +0000 (17:37 +0300)]
Added resolve submodules with raw name
#1211
bors[bot] [Wed, 3 Jul 2019 14:14:13 +0000 (14:14 +0000)]
Merge #1477
1477: Update vsce to 1.64.0 r=matklad a=kjeremy
Gets rid of the annoying warning asking you to run `npm install -g vsce` on `cargo install`.
Co-authored-by: kjeremy <kjeremy@gmail.com>
kjeremy [Wed, 3 Jul 2019 13:55:48 +0000 (09:55 -0400)]
Update vsce to latest
Ekaterina Babshukova [Wed, 3 Jul 2019 13:17:18 +0000 (16:17 +0300)]
extend add_impl_members to constants and types
bors[bot] [Tue, 2 Jul 2019 21:04:08 +0000 (21:04 +0000)]
Merge #1472
1472: Add completion for type aliases r=matklad a=sinkuu
Co-authored-by: Shotaro Yamada <sinkuu@sinkuu.xyz>
Shotaro Yamada [Tue, 2 Jul 2019 18:08:39 +0000 (03:08 +0900)]
Add completion for type aliases
bors[bot] [Tue, 2 Jul 2019 06:48:08 +0000 (06:48 +0000)]
Merge #1468
1468: Use inline snapshots in complete_path r=matklad a=funkill
Relates to #1127
Co-authored-by: funkill2 <funkill2@gmail.com>
funkill2 [Mon, 1 Jul 2019 21:52:03 +0000 (00:52 +0300)]
remove snapshot files
funkill2 [Mon, 1 Jul 2019 21:51:18 +0000 (00:51 +0300)]
inline snapshots
bors[bot] [Sun, 30 Jun 2019 13:36:04 +0000 (13:36 +0000)]
Merge #1465
1465: put source maps first for better stats r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Sun, 30 Jun 2019 13:35:40 +0000 (16:35 +0300)]
put source maps first for better stats
bors[bot] [Sun, 30 Jun 2019 12:03:46 +0000 (12:03 +0000)]
Merge #1464
1464: collect more macros, they are heavy r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Sun, 30 Jun 2019 12:03:23 +0000 (15:03 +0300)]
collect more macros, they are heavy
bors[bot] [Sun, 30 Jun 2019 11:50:11 +0000 (11:50 +0000)]
Merge #1463
1463: print memory usage for queries r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Sun, 30 Jun 2019 11:40:01 +0000 (14:40 +0300)]
print memory usage for queries
bors[bot] [Sun, 30 Jun 2019 10:42:23 +0000 (10:42 +0000)]
Merge #1462
1462: Move memory usage statistics to ra_prof r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Aleksey Kladov [Sun, 30 Jun 2019 10:30:17 +0000 (13:30 +0300)]
Move memory usage statistics to ra_prof
bors[bot] [Sun, 30 Jun 2019 10:17:29 +0000 (10:17 +0000)]
Merge #1458
1458: Run VS Code tests on CI r=matklad a=etaoins
This is actually much faster than I expected; it takes about 13 seconds to download VS Code and run the unit tests. This means the VS Code tests are still significantly faster than the Rust ones.
If this ends up being unreliable we can always remove it later or move it to a separate optional job.
We also need to ignore the `.vscode-test` directory when running `prettier` or it will get upset about some temporary JSON files VS Code creates.
cc @killercup
Co-authored-by: Ryan Cumming <etaoins@gmail.com>
bors[bot] [Sun, 30 Jun 2019 10:05:51 +0000 (10:05 +0000)]
Merge #1461
1461: Support attributes on array members r=matklad a=etaoins
Array members are allowed to have attributes such as `#[cfg]`.
Co-authored-by: Ryan Cumming <etaoins@gmail.com>