about summary refs log tree commit diff
path: root/compiler/rustc_error_codes
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-07-06 20:26:50 +0000
committerbors <bors@rust-lang.org>2024-07-06 20:26:50 +0000
commited7e35f3494045fa1194be29085fa73e2d6dab40 (patch)
tree5dbd26e58a1f27dd18670cd1d22fa0882e6fe2bb /compiler/rustc_error_codes
parent8a8ad3433e4168f54ac1364f85da694be9eeca7c (diff)
parent413345c61dc0bf29e259d2cfd50daaaeab008ea8 (diff)
downloadrust-ed7e35f3494045fa1194be29085fa73e2d6dab40.tar.gz
rust-ed7e35f3494045fa1194be29085fa73e2d6dab40.zip
Auto merge of #127430 - compiler-errors:rollup-76ni16s, r=compiler-errors
Rollup of 4 pull requests

Successful merges:

 - #127386 (Uplift outlives components to `rustc_type_ir`)
 - #127405 (uplift `PredicateEmittingRelation`)
 - #127410 (Correct description of E0502)
 - #127417 (Show fnsig's unit output  explicitly when there is output diff in diagnostics)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_error_codes')
-rw-r--r--compiler/rustc_error_codes/src/error_codes/E0502.md5
1 files changed, 3 insertions, 2 deletions
diff --git a/compiler/rustc_error_codes/src/error_codes/E0502.md b/compiler/rustc_error_codes/src/error_codes/E0502.md
index dc3ffdfddd9..85f38b9286f 100644
--- a/compiler/rustc_error_codes/src/error_codes/E0502.md
+++ b/compiler/rustc_error_codes/src/error_codes/E0502.md
@@ -1,4 +1,5 @@
-A variable already borrowed as immutable was borrowed as mutable.
+A variable already borrowed with a certain mutability (either mutable or
+immutable) was borrowed again with a different mutability.
 
 Erroneous code example:
 
@@ -13,7 +14,7 @@ fn foo(a: &mut i32) {
 ```
 
 To fix this error, ensure that you don't have any other references to the
-variable before trying to access it mutably:
+variable before trying to access it with a different mutability:
 
 ```
 fn bar(x: &mut i32) {}