Add small optimization.

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
Leonardo de Moura 2013-08-10 21:02:45 -07:00
parent 7ebaac62a8
commit 3a1514982f

View file

@ -128,6 +128,9 @@ struct infer_type_fn {
buffer << "\nin context:\n" << ctx;
throw exception(buffer.str());
}
if (closed(c))
f_t = instantiate_with_closed(abst_body(f_t), c);
else
f_t = instantiate(abst_body(f_t), c);
i++;
if (i == num) {