Rollup merge of #26105 - tshepang:sentence-not-clear, r=steveklabnik
This commit is contained in:
commit
0d6f11b09b
1 changed files with 2 additions and 2 deletions
|
@ -1,8 +1,8 @@
|
|||
% Generics
|
||||
|
||||
Sometimes, when writing a function or data type, we may want it to work for
|
||||
multiple types of arguments. Luckily, Rust has a feature that gives us a better
|
||||
way: generics. Generics are called ‘parametric polymorphism’ in type theory,
|
||||
multiple types of arguments. In Rust, we can do this with generics.
|
||||
Generics are called ‘parametric polymorphism’ in type theory,
|
||||
which means that they are types or functions that have multiple forms (‘poly’
|
||||
is multiple, ‘morph’ is form) over a given parameter (‘parametric’).
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue