numpy/numpy — pull request #4985 by larsmans (2014-08-23 16:30:26+00:00)
Title: ENH: np.dot: better "matrices not aligned" message

This scratches a long-standing itch of mine, which is that `np.dot`'s "matrices not aligned" message never explains *which* of the two arguments I forgot to transpose somewhere deep inside an algorithm. This patch makes it report the mismatching pair of dimensions.

It might be even prettier to report the full shape of both inputs, but I think this is a big enough improvement for now.