core.typed

Typechecker fails when checking involves an object from reify

Details

  • Type: Enhancement Enhancement
  • Status: Open Open
  • Priority: Minor Minor
  • Resolution: Unresolved
  • Affects Version/s: None
  • Fix Version/s: Backlog
  • Component/s: Core type system
  • Labels:
  • Environment:
    Clojure 1.6.0, core.typed 0.2.44

Description

The error message is

No method in multimethod 'check' for dispatch value: :reify

The following is a minimal test case which fails:

(ns core-typed-bug.core
  (:require [clojure.core.typed :refer :all]))

(ann-protocol ITypedTest
              get-data [ITypedTest -> Any])
(defprotocol> ITypedTest
  (get-data [this]))

(ann typed-test [String -> ITypedTest])
(defn typed-test [input]
  (reify ITypedTest
    (get-data [_] input)))

(defn> testfn :- Any
  [asdf :- Keyword, in :- ITypedTest]
  (get-data in))

Likely similar to bug CTYP-132.

Activity

People

Vote (1)
Watch (2)

Dates

  • Created:
    Updated: