Small documentation changes
I'm leaving the Sized kind undocumented since it isn't fully implemented yet.
This commit is contained in:
parent
451c94343f
commit
3e265e7842
@ -2869,9 +2869,6 @@ The kinds are:
|
|||||||
: Types of this kind can be safely sent between tasks.
|
: Types of this kind can be safely sent between tasks.
|
||||||
This kind includes scalars, owning pointers, owned closures, and
|
This kind includes scalars, owning pointers, owned closures, and
|
||||||
structural types containing only other owned types. All `Send` types are `Static`.
|
structural types containing only other owned types. All `Send` types are `Static`.
|
||||||
`Static`
|
|
||||||
: Types of this kind do not contain any borrowed pointers;
|
|
||||||
this can be a useful guarantee for code that breaks borrowing assumptions using [`unsafe` operations](#unsafe-functions).
|
|
||||||
`Copy`
|
`Copy`
|
||||||
: This kind includes all types that can be copied. All types with
|
: This kind includes all types that can be copied. All types with
|
||||||
sendable kind are copyable, as are managed boxes, managed closures,
|
sendable kind are copyable, as are managed boxes, managed closures,
|
||||||
|
@ -122,6 +122,7 @@ pub fn xor(a: bool, b: bool) -> bool { (a && !b) || (!a && b) }
|
|||||||
* ~~~ {.rust}
|
* ~~~ {.rust}
|
||||||
* rusti> std::bool::implies(true, true)
|
* rusti> std::bool::implies(true, true)
|
||||||
* true
|
* true
|
||||||
|
* ~~~
|
||||||
*
|
*
|
||||||
* ~~~ {.rust}
|
* ~~~ {.rust}
|
||||||
* rusti> std::bool::implies(true, false)
|
* rusti> std::bool::implies(true, false)
|
||||||
|
@ -18,7 +18,7 @@ intrinsic properties of the type. These classifications, often called
|
|||||||
They cannot be implemented by user code, but are instead implemented
|
They cannot be implemented by user code, but are instead implemented
|
||||||
by the compiler automatically for the types to which they apply.
|
by the compiler automatically for the types to which they apply.
|
||||||
|
|
||||||
The 4 kinds are
|
The 3 kinds are
|
||||||
|
|
||||||
* Copy - types that may be copied without allocation. This includes
|
* Copy - types that may be copied without allocation. This includes
|
||||||
scalar types and managed pointers, and exludes owned pointers. It
|
scalar types and managed pointers, and exludes owned pointers. It
|
||||||
|
Loading…
Reference in New Issue
Block a user