clarify why define_opaque isnt needed

This commit is contained in:
Boxy 2025-12-11 21:18:21 +00:00 committed by GitHub
parent 108bfc13fe
commit e58de3a54c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -85,7 +85,7 @@ impl Baz for Quux {
```
For this you would also need to use `nightly` and the (different) `#![feature(impl_trait_in_assoc_type)]` annotation.
Note that you don't need a `#[define_opaque(Foo)]` on the method anymore.
Note that you don't need a `#[define_opaque(Foo)]` on the method anymore as the opaque type is mentioned in the function signature (behind the associated type).
Complete example:
```