Auto merge of #25440 - durka:patch-3, r=alexcrichton
The Traits chapter uses "adding methods to `int`" as an example of "something bad", but there is no such thing as `int` anymore, right? So I changed it to `i32`.
This commit is contained in:
commit
4ce08a5d70
1 changed files with 1 additions and 1 deletions
|
|
@ -208,7 +208,7 @@ let result = f.write("whatever".as_bytes());
|
|||
|
||||
This will compile without error.
|
||||
|
||||
This means that even if someone does something bad like add methods to `int`,
|
||||
This means that even if someone does something bad like add methods to `i32`,
|
||||
it won’t affect you, unless you `use` that trait.
|
||||
|
||||
There’s one more restriction on implementing traits. Either the trait or the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue