Skip to content

Commit fe34bed

Browse files
authored
Update "Inference variables" section (#1145)
1 parent a58da1b commit fe34bed

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/type-inference.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ inference works, or perhaps this blog post on
7171

7272
[Unification in the Chalk project]: http://smallcultfollowing.com/babysteps/blog/2017/03/25/unification-in-chalk-part-1/
7373

74-
All told, the inference context stores four kinds of inference variables
75-
(as of <!-- date: 2018-01 --> January 2018):
74+
All told, the inference context stores five kinds of inference variables
75+
(as of <!-- date: 2021-06 --> June 2021):
7676

7777
- Type variables, which come in three varieties:
7878
- General type variables (the most common). These can be unified with any
@@ -82,6 +82,7 @@ All told, the inference context stores four kinds of inference variables
8282
- Float type variables, which can only be unified with a float type, and
8383
arise from a float literal expression like `22.0`.
8484
- Region variables, which represent lifetimes, and arise all over the place.
85+
- Const variables, which represent constants.
8586

8687
All the type variables work in much the same way: you can create a new
8788
type variable, and what you get is `Ty<'tcx>` representing an

0 commit comments

Comments
 (0)