<< Back to previous view

[CTYP-112] Better error for type mismatch with loop/recur Created: 04/Mar/14  Updated: 02/Jan/15  Resolved: 02/Jan/15

Status: Closed
Project: core.typed
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Enhancement Priority: Trivial
Reporter: Ambrose Bonnaire-Sergeant Assignee: Ambrose Bonnaire-Sergeant
Resolution: Declined Votes: 0
Labels: None


 Description   

Currently a type error (especially involving locals) that complains about a mismatch to a recur statement could be more descriptive. Perhaps mention where the corresponding loop> is? Should also mention the recur statement.

(loop> [f :- AnyInteger]
(let [n (ann-form 1.2 (U Number nil))]
(recur n)))

Type Error (clojure/math/numeric_tower.clj:89:10) Local binding n530 expected type AnyInteger, but actual type (U Number nil)
in: n530


Generated at Wed Mar 04 17:01:12 CST 2015 using JIRA 4.4#649-r158309.