about summary refs log tree commit diff
path: root/src/librustc/infer/fudge.rs
AgeCommit message (Collapse)AuthorLines
2019-03-27Use Vec instead of FxHashMapvarkor-7/+10
2019-03-27Lookup region variable origin instead of choosing onevarkor-9/+6
2019-03-27Store type variable origins in InferenceFudgervarkor-3/+4
2019-03-27Use `eq_relations`varkor-5/+5
2019-03-27Add `next_int_var` and `next_float_var`varkor-2/+2
2019-03-27Simplify `fudge_inference_if_ok`varkor-19/+19
2019-03-27Add int variables and float variables to `InferenceFudger`varkor-8/+35
2019-03-27Rename `RegionFudger` to `InferenceFudger`varkor-7/+7
2019-03-27Use Ranges for vars_since_snapshotvarkor-31/+28
2019-03-27Make `vars_since_snapshot` naming consistentvarkor-6/+6
2019-02-10rustc: doc commentsAlexander Regueiro-2/+2
2019-02-05move librustc to 2018Mark Mansi-3/+3
2018-12-25Remove licensesMark Rousskov-10/+0
2018-08-22Remove Ty prefix from ↵varkor-1/+1
Ty{Adt|Array|Slice|RawPtr|Ref|FnDef|FnPtr|Dynamic|Closure|Generator|GeneratorWitness|Never|Tuple|Projection|Anon|Infer|Error}
2018-03-23Revert "add universes to type inference variables"Sean Griffin-5/+1
This reverts commit 13efaf0481275dba18f1d18f4b59b664b2d2031a.
2018-03-01add universes to type inference variablesNiko Matsakis-1/+5
2018-03-01have `probe()` return `TypeVariableValue`Niko Matsakis-1/+3
2017-11-16make the `region_constraints` field an `Option`Niko Matsakis-1/+1
This way, we can `take()` ownership of it when we are going to resolve regions.
2017-11-16infer: rename `region_vars` field to `region_constraints`Niko Matsakis-2/+2
2017-11-16move refcells out from `RegionVarBindings` and up into `InferCtxt`Niko Matsakis-1/+1
2017-07-05use field init shorthand in src/librustcZack M. Davis-1/+1
The field init shorthand syntax was stabilized in 1.17.0 (aebd94f); we are now free to use it in the compiler.
2017-04-30intern CodeExtentsNiko Matsakis-1/+1
Make a `CodeExtent<'tcx>` be something allocated in an arena instead of an index into the `RegionMaps`.
2017-04-12do not consult union-find during `fudge_regions_if_ok`Niko Matsakis-12/+4
2017-04-11generalize type variables tooNiko Matsakis-22/+53
When we are generalizing a super/sub-type, we have to replace type variables with a fresh variable (and not just region variables). So if we know that `Box<?T> <: ?U`, for example, we instantiate `?U` with `Box<?V>` and then relate `Box<?T>` to `Box<?V>` (and hence require that `?T <: ?V`). This change has some complex interactions, however: First, the occurs check must be updated to detect constraints like `?T <: ?U` and `?U <: Box<?T>`. If we're not careful, we'll create a never-ending sequence of new variables. To address this, we add a second unification set into `type_variables` that tracks type variables related through **either** equality **or** subtyping, and use that during the occurs-check. Second, the "fudge regions if ok" code was expecting no new type variables to be created. It must be updated to create new type variables outside of the probe. This is relatively straight-forward under the new scheme, since type variables are now independent from one another, and any relations are moderated by pending subtype obliations and so forth. This part would be tricky to backport though. cc #18653 cc #40951
2016-11-08introduce a `fudge_regions_if_ok` to address false region edgesNiko Matsakis-0/+137
Fixes #37655.