Skip to content

Commit

Permalink
Wording changes
Browse files Browse the repository at this point in the history
* Use "special bound syntax" instead of "special syntax". `?Sized` is technically a "bound", but `?Sized` is specialized syntax that _only_ works with `Sized`, and no other Trait.
* Replace "constant size" with "sized".
  • Loading branch information
postmodern committed May 21, 2016
1 parent d8c086b commit 71af58a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/doc/book/unsized-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ pointers, can use this `impl`.
# ?Sized

If you want to write a function that accepts a dynamically sized type, you
can use the special syntax, `?Sized`:
can use the special bound syntax, `?Sized`:

```rust
struct Foo<T: ?Sized> {
Expand All @@ -56,6 +56,6 @@ struct Foo<T: ?Sized> {
```

This `?Sized`, read as “T may or may not be `Sized`”, which allows us to match
both constant size and unsized types. All generic type parameters implicitly
have the `Sized` bound, so `?Sized` can be used to opt-out of the implicit
both sized and unsized types. All generic type parameters implicitly
have the `Sized` bound, so the `?Sized` can be used to opt-out of the implicit
bound.

0 comments on commit 71af58a

Please sign in to comment.