mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 13:25:09 +00:00
Preserve order of generic args
This commit is contained in:
parent
9d473a0b9f
commit
4fa8749c44
39 changed files with 714 additions and 427 deletions
|
@ -2913,6 +2913,27 @@ fn main() {
|
|||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn const_generic_order() {
|
||||
check(
|
||||
r#"
|
||||
struct Foo;
|
||||
struct S$0T<const C: usize = 1, T = Foo>(T);
|
||||
"#,
|
||||
expect![[r#"
|
||||
*ST*
|
||||
|
||||
```rust
|
||||
test
|
||||
```
|
||||
|
||||
```rust
|
||||
struct ST<const C: usize, T = Foo>
|
||||
```
|
||||
"#]],
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn hover_self_param_shows_type() {
|
||||
check(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue