9 Commits

Author SHA1 Message Date
John Ginger
c0e3f4b8bb Change to give a help message 2018-12-07 14:15:36 +00:00
John Ginger
70536d4b4c Fix stderr file (unused variable) 2018-12-03 22:53:03 +00:00
Zack M. Davis
59782f4829 in which the unused shorthand field pattern debacle/saga continues
In e4b1a79 (#47922), we corrected erroneous suggestions for unused
shorthand field pattern bindings, suggesting `field: _` where the
previous suggestion of `_field` wouldn't even have compiled
(#47390). Soon, it was revealed that this was insufficient (#50303), and
the fix was extended to references, slices, &c. (#50327) But even this
proved inadequate, as the erroneous suggestions were still being issued
for patterns in local (`let`) bindings (#50804). Here, we yank the
shorthand-detection and variable/node registration code into a new
common function that can be called while visiting both match arms and
`let` bindings.

Resolves #50804.
2018-05-18 01:00:22 -07:00
csmoe
6c682eb46a reduce variable span 2018-05-13 16:34:27 +08:00
varkor
2eb8343af1 Correct unused field warning on struct match container patterns 2018-04-30 01:27:37 +01:00
varkor
8e8fe9042c Correct unused field warning on box struct match 2018-04-30 00:51:02 +01:00
varkor
cc53db8bf9 Correct unused field warning on &struct match 2018-04-30 00:40:11 +01:00
Vadim Petrochenkov
fa2d9fc4b9 Update UI tests 2018-02-26 20:24:02 +03:00
Zack M. Davis
e4b1a7971d concerning well-formed suggestions for unused shorthand field patterns
Previously, unused variables would get a note that the warning could be
silenced by prefixing the variable with an underscore, but that doesn't
work for field shorthand patterns, which the liveness analysis didn't
know about.

The "to avoid this warning" verbiage seemed unnecessary.

Resolves #47390.
2018-01-31 21:27:16 -08:00