Skip to content

Commit 0a08852

Browse files
committed
Changelog #50
1 parent ecd3e08 commit 0a08852

File tree

3 files changed

+81
-12
lines changed

3 files changed

+81
-12
lines changed

generated_assists.adoc

Lines changed: 27 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//Generated file, do not edit by hand, see `xtask/src/codegen`
22
[discrete]
33
=== `add_custom_impl`
4-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_custom_impl.rs#L14[add_custom_impl.rs]
4+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_custom_impl.rs#L19[add_custom_impl.rs]
55

66
Adds impl block for derived trait.
77

@@ -45,7 +45,7 @@ fn main() {
4545

4646
[discrete]
4747
=== `add_hash`
48-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L91[raw_string.rs]
48+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L92[raw_string.rs]
4949

5050
Adds a hash to a raw string literal.
5151

@@ -66,7 +66,7 @@ fn main() {
6666

6767
[discrete]
6868
=== `add_impl_default_members`
69-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_missing_impl_members.rs#L64[add_missing_impl_members.rs]
69+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_missing_impl_members.rs#L51[add_missing_impl_members.rs]
7070

7171
Adds scaffold for overriding default impl members.
7272

@@ -104,7 +104,7 @@ impl Trait for () {
104104

105105
[discrete]
106106
=== `add_impl_missing_members`
107-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_missing_impl_members.rs#L25[add_missing_impl_members.rs]
107+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/add_missing_impl_members.rs#L12[add_missing_impl_members.rs]
108108

109109
Adds scaffold for required impl members.
110110

@@ -320,7 +320,7 @@ fn qux(bar: Bar, baz: Baz) {}
320320

321321
[discrete]
322322
=== `extract_struct_from_enum_variant`
323-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/extract_struct_from_enum_variant.rs#L18[extract_struct_from_enum_variant.rs]
323+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/extract_struct_from_enum_variant.rs#L19[extract_struct_from_enum_variant.rs]
324324

325325
Extracts a struct from enum variant.
326326

@@ -604,6 +604,24 @@ impl<T: Clone> Ctx<T> {
604604
```
605605

606606

607+
[discrete]
608+
=== `infer_function_return_type`
609+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/infer_function_return_type.rs#L7[infer_function_return_type.rs]
610+
611+
Adds the return type to a function or closure inferred from its tail expression if it doesn't have a return
612+
type specified. This assists is useable in a functions or closures tail expression or return type position.
613+
614+
.Before
615+
```rust
616+
fn foo() { 4┃2i32 }
617+
```
618+
619+
.After
620+
```rust
621+
fn foo() -> i32 { 42i32 }
622+
```
623+
624+
607625
[discrete]
608626
=== `inline_local_variable`
609627
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/inline_local_variable.rs#L13[inline_local_variable.rs]
@@ -681,7 +699,7 @@ fn main() {
681699

682700
[discrete]
683701
=== `make_raw_string`
684-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L13[raw_string.rs]
702+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L8[raw_string.rs]
685703

686704
Adds `r#` to a plain string literal.
687705

@@ -702,7 +720,7 @@ fn main() {
702720

703721
[discrete]
704722
=== `make_usual_string`
705-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L52[raw_string.rs]
723+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L50[raw_string.rs]
706724

707725
Turns a raw string into a plain string.
708726

@@ -898,7 +916,7 @@ fn main() {
898916

899917
[discrete]
900918
=== `remove_hash`
901-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L115[raw_string.rs]
919+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/raw_string.rs#L120[raw_string.rs]
902920

903921
Removes a hash from a raw string literal.
904922

@@ -1081,7 +1099,7 @@ fn process(map: HashMap<String, String>) {}
10811099

10821100
[discrete]
10831101
=== `replace_string_with_char`
1084-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/replace_string_with_char.rs#L9[replace_string_with_char.rs]
1102+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/assists/src/handlers/replace_string_with_char.rs#L5[replace_string_with_char.rs]
10851103

10861104
Replace string with char.
10871105

generated_features.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ Join selected lines into one, smartly fixing up whitespace, trailing commas, and
194194

195195

196196
=== Magic Completions
197-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/completion/src/lib.rs#L25[lib.rs]
197+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/completion/src/lib.rs#L26[lib.rs]
198198

199199
In addition to usual reference completion, rust-analyzer provides some ✨magic✨
200200
completions as well:
@@ -333,7 +333,7 @@ to a shortcut!
333333

334334

335335
=== Semantic Syntax Highlighting
336-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ide/src/syntax_highlighting.rs#L37[syntax_highlighting.rs]
336+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ide/src/syntax_highlighting.rs#L38[syntax_highlighting.rs]
337337

338338
rust-analyzer highlights the code semantically.
339339
For example, `bar` in `foo::Bar` might be colored differently depending on whether `Bar` is an enum or a trait.
@@ -345,7 +345,7 @@ We also give special modifier for `mut` and `&mut` local variables.
345345

346346

347347
=== Show Syntax Tree
348-
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ide/src/syntax_tree.rs#L9[syntax_tree.rs]
348+
**Source:** https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ide/src/syntax_tree.rs#L7[syntax_tree.rs]
349349

350350
Shows the parse tree of the current file. It exists mostly for debugging
351351
rust-analyzer itself.
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
= Changelog #50
2+
:sectanchors:
3+
:page-layout: post
4+
5+
Commit: commit:945900bdbf5423fdfb8542901dfb813c2ec32e09[] +
6+
Release: release:2020-11-09[]
7+
8+
== Sponsors
9+
10+
**Become a sponsor:** On https://opencollective.com/rust-analyzer/[OpenCollective] or
11+
https://github.com/sponsors/rust-analyzer[GitHub Sponsors].
12+
13+
== New Features
14+
15+
* pr:6477[] **Infer Function Return Type** assist.
16+
+
17+
image::https://user-images.githubusercontent.com/1711539/98535642-bf935d00-2286-11eb-98c4-8bdf2c5aa93a.gif[]
18+
* pr:6458[], pr:6476[] **Add Custom Impl** automatically fills-in required methods
19+
+
20+
image::https://user-images.githubusercontent.com/1711539/98534279-84902a00-2284-11eb-8f65-b63c6e27c268.gif[]
21+
* pr:6456[] **Extract Enum Variant** supports records
22+
+
23+
image::https://user-images.githubusercontent.com/1711539/98535147-e7ce8c00-2285-11eb-8b12-802ceb249389.gif[]
24+
* pr:6480[] **Change Return Type to Result** works for closures.
25+
+
26+
image::https://user-images.githubusercontent.com/1711539/98535478-793dfe00-2286-11eb-9e3e-91724a1b93e1.gif[]
27+
* pr:6393[] hide more trivial inlay hints.
28+
* pr:6421[] take some of the `allow(...)` attributes into account when producing rust-analyzer diagnostics.
29+
* pr:6479[] ignore `RUST_SRC_PATH` if it is set to invalid location.
30+
31+
== Fixes
32+
33+
* pr:6436[], pr:6447[], pr:6450[], pr:6488[], pr:6489[], pr:6491[], pr:6497[] fixes to TextMate grammar.
34+
* pr:6441[] don't overload the client with too many progress notifications.
35+
* pr:6399[] keep existing type arguments in the **Qualify Path** assist.
36+
* pr:6401[] fix inlay hints for `self` parameter.
37+
* pr:6287[] auto-import preserves cursor position.
38+
* pr:6454[] fix panic in **Convert Integer Literal** assist.
39+
* pr:6467[] fix stack overflow when module includes itself.
40+
* pr:6470[] fix syntax highlighting flicker.
41+
42+
== Internal Improvements
43+
44+
* pr:6438[] use `-Dunreachable_pub` on CI.
45+
* pr:6490[] minimize **Convert Integer Literal** tests.o
46+
* pr:6437[], pr:6483[] amend code style.
47+
* pr:6442[] upgrade chalk.
48+
* pr:6365[] improve tree diffing algorithm.
49+
* pr:6430[] refactor completion rendering.
50+
* pr:6468[] add issue template.
51+
* pr:6485[] use the same type to represent both `"hello"` and `r#"hello"#` string literals.

0 commit comments

Comments
 (0)