From: Jean Privat Date: Mon, 5 Jan 2015 02:55:06 +0000 (-0500) Subject: rta: `live_targets` do not crash when the receiver is null X-Git-Tag: v0.7.1~45^2~3 X-Git-Url: http://nitlanguage.org rta: `live_targets` do not crash when the receiver is null Signed-off-by: Jean Privat --- diff --git a/src/rapid_type_analysis.nit b/src/rapid_type_analysis.nit index 7881db0..2d9fee4 100644 --- a/src/rapid_type_analysis.nit +++ b/src/rapid_type_analysis.nit @@ -87,8 +87,7 @@ class RapidTypeAnalysis var anchor = callsite.anchor if anchor != null then mtype = mtype.anchor_to(callsite.mmodule, anchor) mtype = mtype.as_notnullable - assert mtype isa MClassType - mtype = mtype.mclass.intro.bound_mtype + if mtype isa MClassType then mtype = mtype.mclass.intro.bound_mtype var mproperty = callsite.mproperty var res = live_targets_cache[mtype, mproperty] if res != null then return res