Commit graph

882 commits

Author SHA1 Message Date
Jeroen Vannevel
8e8e1951e2 whitespace 2022-01-22 12:25:33 +00:00
Jeroen Vannevel
9725eaa21c generated docs 2022-01-22 12:17:24 +00:00
Jeroen Vannevel
61ab31f709 clarify doc 2022-01-22 12:10:48 +00:00
Jeroen Vannevel
4972cb759e Support standalone comments 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
8d61216957 redundant type specified 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
a1c246b1c4 shorter arms 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
4ab7c4d99b removed prints 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
96ab4c6e6c hacky_block_expr_with_comments 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
5d35e5882c removed unwrapping from indent 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
ee862cec10 simplified tail_expr 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
4896ffb65c removing unwraps 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
50c913c733 don't remove the comment token if it's last 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
4f3dd5bc08 very rough but comments get extracted 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
f662d8bf38 repro 2022-01-22 12:08:32 +00:00
Jeroen Vannevel
ffe4352d7c
styling fixes 2022-01-14 18:53:28 +00:00
Jeroen Vannevel
683de877ce
simple return 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
0700282b75
formatting 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
e5cdde95ab
removed toy 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
5e4370fe56
happy slice 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
8deadb18ae
refpat & slicepat 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
82d3238da8
ParenPat 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
c955ea11b4
support TuplePat 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
a347cb5f86
battle of the Some 2022-01-14 01:32:12 +00:00
Jeroen Vannevel
7daca6fe97
cleaning up Some 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
08300284e7
removed unwrap 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
7bc89f2542
formatting 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
bd77d8c3d1
removed prints 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
18fb5412b2
all tests work 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
aaec467cfd
merge_match_arms_nested_with_conflicting_identifier 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
169ec2fdc1
Added a few more test cases 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
b27b882e72
fixed test case 2022-01-14 01:32:11 +00:00
Jeroen Vannevel
2329b42407
test for different number of fields 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
5675e0cd40
test cases with more branches 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
130f11f270
simplified chain 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
5dfc8da77e
don't need the as_ref() 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
c52605024c
extracted function 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
d8a3e51a5f
added tests for multiple fields 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
9252c76255
using classify() 2022-01-14 01:32:10 +00:00
Jeroen Vannevel
6a1b4912bf
removed some unused stuff 2022-01-14 01:32:09 +00:00
Jeroen Vannevel
c9fc91822f
minicore 2022-01-14 01:32:09 +00:00
Jeroen Vannevel
215f896665
compiles, but doesn't work yet 2022-01-14 01:32:09 +00:00
Laurențiu Nicola
0721a55a48 Remove duplicate test attribute 2022-01-13 21:08:04 +02:00
Laurențiu Nicola
84c59a1f9f Reformat code 2022-01-13 21:07:17 +02:00
bors[bot]
c17db9fa53
Merge #11107
11107: Fix generic type substitution in impl trait with assoc type r=pnevyk a=pnevyk

Fixes #11045 

The path transform now detects if a type parameter that is being substituted has an associated type. In that case it is necessary (or safe in general case) to fully qualify the substitution with a trait which the associated type belongs to.

This PR also fixes the previous wrong behavior of the substitution that could create an invalid tree `PATH_TYPE -> PATH_TYPE -> ...`.

Co-authored-by: Petr Nevyhoštěný <petr.nevyhosteny@gmail.com>
2022-01-08 09:05:09 +00:00
Petr Nevyhoštěný
a710b87b1b Fix generic type substitution in impl trait with assoc const 2022-01-07 16:41:39 +01:00
bors[bot]
efb9b89163
Merge #11220
11220: Turbo fish assist: don't include lifetime parameters r=Veykril a=Vannevelj

Fixes #11219

The issue talks about three different types of params: type, const & lifetime. I wasn't entirely sure which ones are intended to be included here so I've gone for the type & const params (i.e. exclude lifetime).

I've added a test case for both a lifetime param and a const param. I'm still making my way through the rust book (chapter 7, yay) so I'm not too sure yet what these are but my testing shows that this approach generates code that compiles.

Co-authored-by: Jeroen Vannevel <jer_vannevel@outlook.com>
2022-01-07 14:02:01 +00:00
Jeroen Vannevel
0a240e31c5
succinct code 2022-01-07 13:53:42 +00:00
bors[bot]
c09504bd58
Merge #11194
11194: fix(gen-doc-assist): remove lifetimes in description of `new` r=Veykril a=numero-744

From wrong behavior:

```rust
/// Creates a new [`MyGenericStruct<'a, T>`].
```

to correct behavior:

```rust
/// Creates a new [`MyGenericStruct<T>`].
```

But I feel like there is a better way to implement it. Do you know if there is an existing function that could do the work of `lifetimes_removed()` below?

Co-authored-by: Côme ALLART <come.allart@etu.emse.fr>
2022-01-07 13:24:58 +00:00
Jeroen Vannevel
4bcdb05325
include tabstops 2022-01-07 13:17:21 +00:00
Côme ALLART
1b5c60f549 refactor: apply suggestions
See PR #11194
2022-01-07 14:07:35 +01:00