From cfa1de72ebb7060a82dbf7a67432047d9ea2288a Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Wed, 26 Dec 2018 17:00:42 +0100 Subject: Implement type variables This will really become necessary when we implement generics, but even now, it allows us to reason 'backwards' to infer types of expressions that we didn't understand for some reason. We use ena, the union-find implementation extracted from rustc, to keep track of type variables. --- crates/ra_hir/src/ty/tests/data/0004_struct.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crates/ra_hir/src/ty/tests/data/0004_struct.txt') diff --git a/crates/ra_hir/src/ty/tests/data/0004_struct.txt b/crates/ra_hir/src/ty/tests/data/0004_struct.txt index cc8f3665b..b4af18b87 100644 --- a/crates/ra_hir/src/ty/tests/data/0004_struct.txt +++ b/crates/ra_hir/src/ty/tests/data/0004_struct.txt @@ -1,5 +1,5 @@ [86; 90) 'C(1)': [unknown] -[121; 122) 'B': [unknown] +[121; 122) 'B': B [86; 87) 'C': [unknown] [129; 130) '1': [unknown] [107; 108) 'a': A @@ -13,4 +13,4 @@ [96; 97) 'B': [unknown] [88; 89) '1': [unknown] [82; 83) 'c': [unknown] -[127; 131) 'C(1)': [unknown] +[127; 131) 'C(1)': C -- cgit v1.2.3