diff options
author | John Hodge <tpg@mutabah.net> | 2016-11-27 13:30:41 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2016-11-27 13:30:41 +0800 |
commit | 4e9d392a6db70d13cf416848c0a8744044cf4e95 (patch) | |
tree | 51b9271ad58d8da4dc3cae4ec4b46fb4286f8de5 | |
parent | 61c3857959b4e904a6dd5e7809355395a0ebb769 (diff) | |
download | mrust-4e9d392a6db70d13cf416848c0a8744044cf4e95.tar.gz |
HIR Typecheck Expr - Don't take guesses if an ivar was aliased
-rw-r--r-- | src/hir_typeck/expr_cs.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hir_typeck/expr_cs.cpp b/src/hir_typeck/expr_cs.cpp index a8524d71..8c498220 100644 --- a/src/hir_typeck/expr_cs.cpp +++ b/src/hir_typeck/expr_cs.cpp @@ -5081,7 +5081,7 @@ namespace { ty_l_ivar.m_data.as_Infer().index = i; const auto& ty_l = context.m_ivars.get_type(ty_l_ivar); - if( !ty_l.m_data.is_Infer() ) { + if( ty_l != ty_l_ivar ) { DEBUG("- IVar " << i << " had possibilities, but was known to be " << ty_l); // Completely clear by reinitialising ivar_ent = Context::IVarPossible(); |