Skip to content

Commit 8a8d620

Browse files
committed
Add a generic introduction to the generics chapter
This may not be terribly useful, but it felt awkward not having something here.
1 parent f165187 commit 8a8d620

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/types/generics.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
r[generics]
22
# Generics
33

4+
r[generics.intro]
5+
Generics allow items to be parameterized by types, lifetimes, and constants. This allows definitions to be written in a flexible way that can be reused with different concrete types and values.
6+
47
r[generics.parameters]
58
## Generic parameters
69

0 commit comments

Comments
 (0)