I have two questions about spec and ns. In clojure/core/specs.clj: * both ::ns-require and ::prefix-list use s/cat. * ::refer uses s/coll-of.
So both list and vector could be used, right? i.e. the following ns declarations work in 1.9.0-alpha11: * (ns n (:require [clojure.set :refer [map-invert]])) * (ns n *[*:require [clojure.set :refer [map-invert]]*]*) * (ns n [:require [clojure.set :refer *(*map-invert*)*]]) *Q1*: Are all of these intended behaviors? There are cases that some of the expanded expressions will fail at runtime while the original (ns ...) will pass the spec: * (require '(clojure.set :refer [map-invert])) one of the expression produced by (ns n [:require *(*clojure.set :refer [map-invert]*)*]). * (require) produced by (ns n (:require)). In the (ns n (:require)) case, we could simply: * change ns so that it will discard (:require) completely. * change s/* to s/+ in ::ns-require. But there exists many other mismatches between specs and implementations. Some of them may be subtler or more complicated than (ns n (:require)) and couldn't be fixed easily. *Q2*: When mismatches occurs, which one(the spec, the current implementation or none of them) should be taken as the formal definition of Clojure language? Thanks! -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.