Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 1d0ad04

Browse files
author
The Miri Cronjob Bot
committedMay 25, 2024
Merge from rustc
2 parents 3cfcfbf + 21e6de7 commit 1d0ad04

File tree

71 files changed

+809
-584
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+809
-584
lines changed
 

‎compiler/rustc_hir_typeck/src/op.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -381,10 +381,13 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
381381
let maybe_missing_semi = self.check_for_missing_semi(expr, &mut err);
382382

383383
// We defer to the later error produced by `check_lhs_assignable`.
384-
// We only downgrade this if it's the LHS, though.
384+
// We only downgrade this if it's the LHS, though, and if this is a
385+
// valid assignment statement.
385386
if maybe_missing_semi
386387
&& let hir::Node::Expr(parent) = self.tcx.parent_hir_node(expr.hir_id)
387388
&& let hir::ExprKind::Assign(lhs, _, _) = parent.kind
389+
&& let hir::Node::Stmt(stmt) = self.tcx.parent_hir_node(parent.hir_id)
390+
&& let hir::StmtKind::Expr(_) | hir::StmtKind::Semi(_) = stmt.kind
388391
&& lhs.hir_id == expr.hir_id
389392
{
390393
err.downgrade_to_delayed_bug();

‎compiler/rustc_incremental/src/persist/load.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,7 @@ fn load_dep_graph(sess: &Session) -> LoadResult<(Arc<SerializedDepGraph>, WorkPr
116116

117117
if let LoadResult::Ok { data: (work_products_data, start_pos) } = load_result {
118118
// Decode the list of work_products
119-
let Ok(mut work_product_decoder) =
120-
MemDecoder::new(&work_products_data[..], start_pos)
119+
let Ok(mut work_product_decoder) = MemDecoder::new(&work_products_data[..], start_pos)
121120
else {
122121
sess.dcx().emit_warn(errors::CorruptFile { path: &work_products_path });
123122
return LoadResult::DataOutOfDate;
There was a problem loading the remainder of the diff.

0 commit comments

Comments
 (0)
Failed to load comments.