@@ -102,10 +102,10 @@ Modelling polymorphic type declarations
102
102
---------------------------------------
103
103
104
104
The partial application scheme gives us a new -- and quite elegant --
105
- way to do higher-kinded types. But how do we interprete the
105
+ way to do certain higher-kinded types. But how do we interprete the
106
106
poymorphic types that exist in current Scala?
107
107
108
- More concretely, current Scala allows us to write parameterize type
108
+ More concretely, current Scala allows us to write parameterized type
109
109
definitions, abstract types, and type parameters. In the new scheme,
110
110
only classes (and traits) can have parameters and these are treated as
111
111
equivalent to type members. Type aliases and abstract types do not
@@ -128,11 +128,11 @@ Here, `Lambda1` is a standard trait defined as follows:
128
128
129
129
trait Lambda1[type Arg1, type Apply]
130
130
131
- According to our definitions of type parameters ` Lambda1 ` has two type parameters
131
+ According to our definitions of type parameters, ` Lambda1 ` has two type parameters
132
132
and ` Pair ` has one.
133
133
134
134
There are ` LambdaN ` traits for higher arities as well. ` Lambda ` traits are special in that
135
- they influence how type applications are expanded: If standard type applicatuon ` T[X1, ..., Xn] `
135
+ they influence how type applications are expanded: If the standard type application ` T[X1, ..., Xn] `
136
136
leads to a subtype ` S ` of a type instance
137
137
138
138
LambdaN { type Arg1 = T1; ...; type ArgN = Tn; type Apply ... }
@@ -145,7 +145,7 @@ For instance, the type instance `Pair[String]` would be expanded to
145
145
146
146
Lambda1 { type Arg1 = String; type Apply = (Arg1, Arg1) } # Apply
147
147
148
- which turns out to be equal to ` (String, String) ` .
148
+ which in turn equals ` (String, String) ` .
149
149
150
150
2nd Example: Consider the two aliases
151
151
0 commit comments