Fix typo/minor grammar error in subtyping.md (#317)

pull/319/head
Victor Costan 3 years ago committed by GitHub
parent 650d2454d7
commit 2d66852a27
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -418,7 +418,7 @@ And that's why function types, unlike anything else in the language, are
**contra**variant over their arguments.
Now, this is all well and good for the types the standard library provides, but
how is variance determined for type that *you* define? A struct, informally
how is variance determined for types that *you* define? A struct, informally
speaking, inherits the variance of its fields. If a struct `MyType`
has a generic argument `A` that is used in a field `a`, then MyType's variance
over `A` is exactly `a`'s variance over `A`.

Loading…
Cancel
Save