(Array X) is broken and undocumented

Description

There is no documentation about (Array X) in the API docs: http://clojure.github.io/core.typed/#clojure.core.typed - it was hard to find our that such a thing existed.

Environment

None

Activity

Show:
Ambrose Bonnaire-Sergeant
June 23, 2015, 2:50 PM

The implementation is fast and loose about the distinction of byte and Byte too – they're pretty much identical, since Clojure does the appropriate coercions at runtime. Also be careful about that.

Marc O'Morain
June 23, 2015, 2:39 PM

We have a few uses of Array in our code-base. The few I have been touching today are for annotating clojure.java.io signatures. We don't use the byte[] forms of the functions at present, so we should be OK for now.

Thanks

Ambrose Bonnaire-Sergeant
June 23, 2015, 2:26 PM

Unfortunately it's intentional. It's a long standing issue, one that I've thought long and hard about, but Arrays broken right now. The main problem is that there is no distinction between an array of boxed values and an array of unboxed values – you can upcast from one the other.

I will put this near the top of the list of things to do.

Your pinned fields
Click on the next to a field label to start pinning.

Assignee

Unassigned

Reporter

Marc O'Morain