Uploaded image for project: 'core.typed'
  1. CTYP-133

Typechecker fails when checking involves an object from reify

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects versions: None
    • Fix versions: Backlog
    • Components: Core type system
    • Labels:
      None
    • 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.

      Branch: https://github.com/clojure/core.typed/pull/28/files

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              alex+import import
            • Votes:
              2 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: