<p dir="auto">It seems likely that 0.4 will see a transition to array views (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="26319160" data-permission-text="Title is private" data-url="https://github.com/JuliaLang/julia/issues/5556" data-hovercard-type="pull_request" data-hovercard-url="/JuliaLang/julia/pull/5556/hovercard" href="https://github.com/JuliaLang/julia/pull/5556">#5556</a>). This change will surely break some code, e.g., for anyone who was relying on the behavior of <code class="notranslate">setindex!</code> applied to the output of <code class="notranslate">A[3:15, 7]</code>. Perhaps we should take the occasion to simultaneously think about another (much worse) breakage.</p>
<p dir="auto">As we've gotten less concerned about breaking Matlab compatibility (and as I've learned more about the wider scientific ecosystem), I've increasingly begun to wonder whether NumPy's slicing rules are the right way to go. It's very simple: if you index along a particular dimension with an <code class="notranslate">AbstractVector</code>, that dimension is retained; if you index with a scalar, that dimension is dropped. So for a 2d array <code class="notranslate">A</code>, <code class="notranslate">A[:,:]</code> produces 2d output, <code class="notranslate">A[3,:]</code> and <code class="notranslate">A[:,3]</code> both produce 1d output, and <code class="notranslate">A[3:3,:]</code>, <code class="notranslate">A[:,3:3]</code> both produce 2d output. Note this scheme is type-stable, so AFAICT there are no performance gotchas.</p>
<p dir="auto">But wow would it be a breaking change.</p>
<p dir="auto">I fixed complex dot(), but it still does not work correctly. I can't figure out what might be wrong. The only thing I can think of is that the C interface probably does not know how to return complex numbers.</p>