On Fri, Jun 18, 2010 at 12:24 AM, Antony Blakey <antony.bla...@gmail.com>wrote:

>
> That's fine for fact, but as a consumer of library functions, how do I know
> when I should pass in bigints? How do I know when an intermediate value, for
> my particular combination of parameter values, is going to overflow?
>

If the library isn't communicating that to you isn't that just a broken API
that you don't want to participate in? Tag information on arglists is
available:

(defn foo [^BigInteger a b ^BigInteger c]
  (+ a b))
(print (map (fn [xs] (map meta xs)) (:arglists (meta #'foo))))

;(({:tag BigInteger} nil {:tag BigInteger}))

IDEs can easily (and should) expose this.

David

-- 
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

Reply via email to