Rollup merge of #102820 - ehuss:let-else-nightly-suggestion, r=petrochenkov

Show let-else suggestion on stable.

The E0005 error message has a suggestion to use let-else. Now that let-else is stabilized, I think this message should be included on non-nightly toolchains. I suspect this was just an oversight from #93628.  [`E0005.stderr`](be1c7aad72/src/test/ui/error-codes/E0005.stderr (L22-L25)) contains an example of what this suggestion looks like.
This commit is contained in:
Yuki Okushi 2022-10-10 00:09:41 +09:00 committed by GitHub
commit c5d4456564
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -491,7 +491,7 @@ impl<'p, 'tcx> MatchVisitor<'_, 'p, 'tcx> {
], ],
Applicability::HasPlaceholders, Applicability::HasPlaceholders,
); );
if !bindings.is_empty() && cx.tcx.sess.is_nightly_build() { if !bindings.is_empty() {
err.span_suggestion_verbose( err.span_suggestion_verbose(
semi_span.shrink_to_lo(), semi_span.shrink_to_lo(),
&format!( &format!(