aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_assists/src/handlers/add_missing_impl_members.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-06-12 15:28:40 +0100
committerGitHub <[email protected]>2020-06-12 15:28:40 +0100
commitb56ad148db0c69eb279c225f45d324b4e80e7367 (patch)
treee900043096a53b92b96ea4eec77d158bc4991717 /crates/ra_assists/src/handlers/add_missing_impl_members.rs
parentf3d73865d6ce6989018b3ebee8e199853253bfd7 (diff)
parent591b5ec2c15a83fd10da7049b5f3ea1a783d52ed (diff)
Merge #4857
4857: Fix invalid shorthand initialization diagnostic for tuple structs r=jonas-schievink a=OptimalStrategy Initializing tuple structs explicitly, like in the example below, produces a "Shorthand struct initialization" diagnostic that leads to a compilation error when applied: ```rust struct S(usize); fn main() { let s = S { 0: 0 }; // OK, but triggers the diagnostic // let s = S { 0 }; // Compilation error } ``` This PR adds a check that the field name is not a literal. Co-authored-by: OptimalStrategy <[email protected]> Co-authored-by: OptimalStrategy <[email protected]>
Diffstat (limited to 'crates/ra_assists/src/handlers/add_missing_impl_members.rs')
0 files changed, 0 insertions, 0 deletions