@@ -7,8 +7,9 @@ the structure of the program when the compiler is compiling it.
7
7
8
8
### Arity
9
9
10
- Arity refers to the number of arguments a function or operation takes.
11
- For example, ` f(2, 3) ` and ` g(4, 6) ` have arity 2, while ` h(8, 2, 6) ` has arity 3.
10
+ Arity refers to the number of arguments a function or operator takes.
11
+ For some examples, ` f(2, 3) ` and ` g(4, 6) ` have arity 2, while ` h(8, 2, 6) `
12
+ has arity 3. The ` ! ` operator has arity 1.
12
13
13
14
### Array
14
15
@@ -19,9 +20,8 @@ at run time by the program. It occupies a contiguous region of memory.
19
20
### Associated Item
20
21
21
22
An associated item is an item that is associated with another item. Associated
22
- items are defined in [ implementations] and [ traits] . Only functions, constants,
23
- and types can be associated.
24
-
23
+ items are defined in [ implementations] and declared in [ traits] . Only functions,
24
+ constants, and type aliases can be associated.
25
25
26
26
### Bound
27
27
@@ -61,8 +61,8 @@ can create such an lvalue without initializing it.
61
61
62
62
### Nominal Types
63
63
64
- Types that can be named directly. Specifically [ enums] , [ structs ] , [ unions ] ,
65
- and [ trait objects] .
64
+ Types that can be referred to by a path directly. Specifically [ enums] ,
65
+ [ structs ] , [ unions ] , and [ trait objects] .
66
66
67
67
### Prelude
68
68
@@ -100,9 +100,9 @@ Strings slices are always valid UTF-8.
100
100
### Trait
101
101
102
102
A trait is a language item that is used for describing the functionalities a type must provide.
103
- It allow a type to make certain promises about its behavior.
103
+ It allows a type to make certain promises about its behavior.
104
104
105
- Generic functions and generic structs can exploit traits to constrain, or bound, the types they accept.
105
+ Generic functions and generic structs can use traits to constrain, or bound, the types they accept.
106
106
107
107
[ enums ] : items/enumerations.html
108
108
[ structs ] : items/structs.html
0 commit comments