我正在阅读 Rust 的 RFC 0401看看这个:
coerce_inner(
Foo<..., T, ...>
) =Foo<..., coerce_inner(T), ...>
whereFoo
is a struct and only the last field has typeT
andT
is not part of the type of any other fields;coerce_inner(
(..., T)
) =(..., coerce_inner(T))
.
这是最新信息吗?如果是,这有什么用?
最佳答案
它们用于将具有大小“尾部”的结构/元组转换为未大小的结构/元组。
关于rust - RFC 401 的 coerce_inner 有什么用?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38010241/