Skip to content

Commit

Permalink
Merge pull request #1240 from pierwill/patch-1
Browse files Browse the repository at this point in the history
Update subtyping.md
  • Loading branch information
Havvy authored Aug 14, 2022
2 parents 36d863b + 36a66c0 commit e1dc762
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/subtyping.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Subtyping and Variance

Subtyping is implicit and can occur at any stage in type checking or
inference. Subtyping in Rust is very restricted and occurs only due to
inference. Subtyping is restricted to two cases:
variance with respect to lifetimes and between types with higher ranked
lifetimes. If we were to erase lifetimes from types, then the only subtyping
would be due to type equality.
Expand Down

0 comments on commit e1dc762

Please sign in to comment.