The current behavior is useful in a number of contexts; for example, you can write algorithms that take either a Vector or Matrix input without having to reshape to a matrix. Note that you can index a vector as v[i,1] without error, too.
But if you have a compelling example of where this leads to bad behavior, please do share it. --Tim On Monday, May 12, 2014 10:29:36 PM Ganesh Rapolu wrote: > For an array A if n > ndims(A), then size(A,n) currently returns 1. Is this > an error or is there some reasoning behind this? It does the right thing > (gives an error saying "dimension out of range") when n <= 0. Also I wanted > to add that I am enjoying Julia a lot! You guys did a great job with the > language.
