@@ -199,6 +199,10 @@ relate to converting types to unsized types, and are permitted in a few
199199cases where other coercions are not, as described above. They can still happen
200200anywhere else a coercion can occur.
201201
202+ r[ coerce.unsize.misnomer]
203+ > Note: "unsizing" is a bit of a misnomer,
204+ > since this covers unsized->unsized coercions too.
205+
202206r[ coerce.unsize.trait]
203207Two traits, [ ` Unsize ` ] and [ ` CoerceUnsized ` ] , are used
204208to assist in this process and expose it for library use. The following
@@ -213,6 +217,8 @@ r[coerce.unsize.trait-object]
213217
214218r[ coerce.unsize.trait-upcast]
215219* ` dyn T ` to ` dyn U ` , when ` U ` is one of ` T ` 's supertraits.
220+ * ` dyn T ` to ` dyn U ` when ` U ` is one of ` T ` 's [ supertraits] .
221+ * This allows dropping auto traits, i.e. ` dyn T + Auto ` to ` dyn U ` is allowed.
216222
217223r[ coerce.unsized.composite]
218224* ` Foo<..., T, ...> ` to ` Foo<..., U, ...> ` , when:
@@ -330,3 +336,4 @@ precisely.
330336[ `Unsize` ] : std::marker::Unsize
331337[ `CoerceUnsized` ] : std::ops::CoerceUnsized
332338[ method-call expressions ] : expressions/method-call-expr.md
339+ [ supertraits ] : items/traits.md#supertraits
0 commit comments