diff options
| author | surechen <chenshuo17@huawei.com> | 2024-06-25 10:00:30 +0800 |
|---|---|---|
| committer | surechen <chenshuo17@huawei.com> | 2024-06-25 10:00:30 +0800 |
| commit | 2a6a42329f79d3c2a42f23ca9fb68aba511a2bc1 (patch) | |
| tree | bbb5056488b24270c4f12f2b8653c4eb39b16edf /tests/ui/error-codes | |
| parent | 4e63822fc4e2ca675dd28bb3f332f7fd4f3f8126 (diff) | |
| download | rust-2a6a42329f79d3c2a42f23ca9fb68aba511a2bc1.tar.gz rust-2a6a42329f79d3c2a42f23ca9fb68aba511a2bc1.zip | |
Change E0369 diagnostic give note information for foreign items.
Make it easy for developers to understand why the binop cannot be applied. fixes #125631
Diffstat (limited to 'tests/ui/error-codes')
| -rw-r--r-- | tests/ui/error-codes/E0067.stderr | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/ui/error-codes/E0067.stderr b/tests/ui/error-codes/E0067.stderr index ec0358cb7df..71b72080544 100644 --- a/tests/ui/error-codes/E0067.stderr +++ b/tests/ui/error-codes/E0067.stderr @@ -5,6 +5,12 @@ LL | LinkedList::new() += 1; | -----------------^^^^^ | | | cannot use `+=` on type `LinkedList<_>` + | +note: the foreign item type `LinkedList<_>` doesn't implement `AddAssign<{integer}>` + --> $SRC_DIR/alloc/src/collections/linked_list.rs:LL:COL + ::: $SRC_DIR/alloc/src/collections/linked_list.rs:LL:COL + | + = note: not implement `AddAssign<{integer}>` error[E0067]: invalid left-hand side of assignment --> $DIR/E0067.rs:4:23 |
