clojure-dev

Issues: https://clojure.atlassian.net/browse/CLJ | Guide: https://insideclojure.org/2015/05/01/contributing-clojure/
devn 2019-05-09T20:55:17.116700Z

Well, that's almost certainly way oversimplified. The rabbit hole looks rather deep. Thoughts on approach welcome.

2019-05-09T21:10:55.117200Z

devn What is the rabbit hole that this patch leads to?

2019-05-09T22:04:23.118200Z

I don't think making seq work on transients would be a viable solution

2019-05-09T22:04:44.118600Z

only way to do that would be to make a full copy of the data structure, is my hasty guess

2019-05-09T22:05:15.119Z

(defn empty? [c] (zero? (count c))) works for transients

2019-05-09T22:05:46.119800Z

I'm not sure that suggests any good implementation though; you wouldn't want to use that on lazy collections

2019-05-09T22:06:18.120200Z

switching on whether it's a transient or not leads to the old "does it make normal things slower?" conundrum

2019-05-09T22:06:56.120500Z

the most plausible thing I can imagine is rewriting empty? in terms of a new interface or protocol

2019-05-09T22:07:16.120800Z

which sounds like at least moderately sized work