One thing that’s special about arrays is memory alignment.
Modern computers work by running through a list of instructions which operate on some data the CPU has loaded from RAM. Some amount of that data is cached closer to the CPU, which speeds up accessing that data. The smallest data that can be loaded is usually a so called “word”. On 64 bit systems, a word consists of 8 bytes, on 32 bit systems of 4 bytes. Each datapoint you want to load lives at some place in memory, which is addressed by a pointer (basically a fancy unsigned integer). Here’s the catch: if the data you want to load sits at an address that isn’t a multiple of 8 (or 4 in case of 32 bit), the CPU has to do a lot more work to load that data, because (usually) only multiples of 8 are addressable. In that case, the CPU has to do 2 loads and retrieve the data from the two words. The same goes for storing the data back into memory. Since julia doesn’t expose this reality of caches and memory and how computers actually work, you can’t ensure memory alignment through julias semantics. The implementation of the memory allocator julia uses is done in C, which does expose this, at the expense of it being opaque for regular julia code.
Further, some instructions can operate on more than one word at the same time or split up words into smaller chunks and operate on all of the chunks at the same time. In those cases, you want your data to be aligned to even more than 8 bytes - julia by default uses (if I recall correctly) 16 bytes. This allows for SIMD on already aligned data.
As far as I know, this is the biggest reason arrays are not done in pure julia.
I’m not a core developer and I’ve only glossed over the array.c implementation, so take what I’ve written above with a big spoonful of salt There are also a lot of details missing. It’s just something that came up when I thought about what would be needed to implement a pure julia array from scratch.
If you want to have a (small) primer on data alignment and related problems, check out the wikipedia article, it’s a fairly nice introduction (which again ignores a lot of details).