diff options
| author | Esteban Küber <esteban@kuber.com.ar> | 2024-11-28 20:22:46 +0000 |
|---|---|---|
| committer | Esteban Küber <esteban@kuber.com.ar> | 2024-12-07 21:29:58 +0000 |
| commit | 3f2a63a68bbf4e84f7e409659bb64bdd75db39e5 (patch) | |
| tree | 166009f66e64ed030618966ab5acbad10f2d64c4 /tests/ui/async-await/issue-86507.stderr | |
| parent | 568b0ac624553150330f1cc3bbff9b99e5d358a2 (diff) | |
| download | rust-3f2a63a68bbf4e84f7e409659bb64bdd75db39e5.tar.gz rust-3f2a63a68bbf4e84f7e409659bb64bdd75db39e5.zip | |
Use trait name instead of full constraint in suggestion message
```
help: consider restricting type parameter `T` with traits `Copy` and `Trait`
|
LL | fn duplicate_custom<T: Copy + Trait>(t: S<T>) -> (S<T>, S<T>) {
| ++++++++++++++
```
```
help: consider restricting type parameter `V` with trait `Copy`
|
LL | fn index<'a, K, V: std::marker::Copy>(map: &'a HashMap<K, V>, k: K) -> &'a V {
| +++++++++++++++++++
```
Diffstat (limited to 'tests/ui/async-await/issue-86507.stderr')
| -rw-r--r-- | tests/ui/async-await/issue-86507.stderr | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/ui/async-await/issue-86507.stderr b/tests/ui/async-await/issue-86507.stderr index be0c6563391..781ff8fddd1 100644 --- a/tests/ui/async-await/issue-86507.stderr +++ b/tests/ui/async-await/issue-86507.stderr @@ -14,7 +14,7 @@ note: captured value is not `Send` because `&` references cannot be sent unless LL | let x = x; | ^ has type `&T` which is not `Send`, because `T` is not `Sync` = note: required for the cast from `Pin<Box<{async block@$DIR/issue-86507.rs:18:17: 18:27}>>` to `Pin<Box<(dyn Future<Output = ()> + Send + 'async_trait)>>` -help: consider further restricting this bound with trait `std::marker::Sync` +help: consider further restricting this bound with trait `Sync` | LL | fn bar<'me, 'async_trait, T: Send + std::marker::Sync>(x: &'me T) | +++++++++++++++++++ |
