1. (def-alias SLiteral (U Symbol
  2. (Option (Seqable SLiteral))))
  3. (ann s-check (predicate Symbol))
  4. (defn s-check
  5. [x]
  6. (symbol? x))
  7. (ann s-test (Fn [SLiteral -> SLiteral]))
  8. (defn s-test
  9. [sliteral]
  10. (if (s-check sliteral)
  11. 'win
  12. (second sliteral)))
  13. Expected: (Fn [Any -> boolean :filters {:then (is clojure.lang.Symbol 0), :else (! clojure.lang.Symbol 0)}])
  14. Actual: (Fn [Any -> boolean :filters {:then (& (is clojure.lang.Symbol 0) (is clojure.lang.Symbol 0)), :else (! clojure.lang.Symbol 0)}])
  15. in: (def s-check (fn* ([x] (clojure.core/symbol? x))))
Comments powered by Disqus