Skip to content

Commit 75291ee

Browse files
authored
Update compiler/rustc_typeck/src/expr_use_visitor.rs
1 parent c4ac836 commit 75291ee

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

compiler/rustc_typeck/src/expr_use_visitor.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ pub trait Delegate<'tcx> {
3030
// on `mode`. Where `diag_expr_id` is the id used for diagnostics for `place`.
3131
//
3232
// Use of a `Copy` type in a ByValue context is considered a use
33-
// by `ImmBorrow` and `borrow` is called instead.
33+
// by `ImmBorrow` and `borrow` is called instead. This is because
34+
// a shared borrow is the "minimum access" that would be needed
35+
// to perform a copy.
3436
//
3537
//
3638
// The parameter `diag_expr_id` indicates the HIR id that ought to be used for

0 commit comments

Comments
 (0)