@@ -195,6 +195,10 @@ relate to converting types to unsized types, and are permitted in a few
195195cases where other coercions are not, as described above. They can still happen
196196anywhere else a coercion can occur.
197197
198+ r[ coerce.unsize.misnomer]
199+ > Note: "unsizing" is a bit of a misnomer,
200+ > since this covers unsized->unsized coercions too.
201+
198202r[ coerce.unsize.trait]
199203Two traits, [ ` Unsize ` ] and [ ` CoerceUnsized ` ] , are used
200204to assist in this process and expose it for library use. The following
@@ -208,7 +212,8 @@ r[coerce.unsize.trait-object]
208212* ` T ` to ` dyn U ` , when ` T ` implements ` U + Sized ` , and ` U ` is [ dyn compatible] .
209213
210214r[ coerce.unsize.trait-upcast]
211- * ` dyn T ` to ` dyn U ` , when ` U ` is one of ` T ` 's supertraits.
215+ * ` dyn T ` to ` dyn U ` , when ` U ` is one of ` T ` 's [ supertraits] .
216+ * This allows dropping auto traits, i.e. ` dyn T + Auto ` to ` dyn U ` is allowed.
212217
213218r[ coerce.unsized.composite]
214219* ` Foo<..., T, ...> ` to ` Foo<..., U, ...> ` , when:
@@ -325,3 +330,4 @@ precisely.
325330[ `Unsize` ] : std::marker::Unsize
326331[ `CoerceUnsized` ] : std::ops::CoerceUnsized
327332[ method-call expressions ] : expressions/method-call-expr.md
333+ [ supertraits ] : items/traits.md#supertraits
0 commit comments