<< Back to previous view

[CTYP-123] Using clojure.core.typed.async requires calling typed-deps Created: 16/Mar/14  Updated: 20/Jul/14  Resolved: 20/Jul/14

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

Type: Defect Priority: Major
Reporter: Gary Fredericks Assignee: Ambrose Bonnaire-Sergeant
Resolution: Completed Votes: 0
Labels: None
Environment:

0.2.38-20140315.151412-2



 Description   

The following code will only type check if (t/typed-deps clojure.core.typed.async) is added below the ns form:

(ns controller.tmp
  (:require [clojure.core.async :as a]
            [clojure.core.typed :as t]
            [clojure.core.typed.async :as t.a]))

(t/ann my-chan [-> (t.a/Chan Number)])
(defn my-chan [] (t.a/chan> Number))

;; (t/check-ns):
;;
;; WARNING: Type Checker: Definition missing: clojure.core.async/chan
;; Hint: Use :no-check metadata with ann if this is an unchecked var
;; Checked 1 namespaces (approx. 18 lines) in 7241.543591 msecs
;; Type Error (controller/tmp.clj:18:18) Unannotated var clojure.core.async/chan
;; Hint: Add the annotation for clojure.core.async/chan via check-ns or cf
;; in: clojure.core.async/chan
;;
;;
;; Type Error (controller/tmp.clj:18:18) Cannot instantiate non-polymorphic type: Error
;; in: clojure.core.async/chan
;;
;;
;; ExceptionInfo Type Checker: Found 2 errors  
;; clojure.core/ex-info (core.clj:4403)


 Comments   
Comment by Ambrose Bonnaire-Sergeant [ 20/Jul/14 5:35 AM ]

Fixed sometime before 0.2.58

Generated at Tue Oct 21 02:30:40 CDT 2014 using JIRA 4.4#649-r158309.