This isn't quite what you asked for, but I've run into problems where the distinction between scalars and 1x1 matrices was important. iirc, something like
crossprod(y, crossprod(A, y)) * V
where A was nxn, y was nx1, and V was an arbitrary matrix throws an error while