There exists a generic folding facility that folds the operand of a memref_cast
into users of memref_cast that support this. However, it was not used for the
memref_cast itself. Fix it to enable elimination of memref_cast chains such as
%1 = memref_cast %0 : A to B %2 = memref_cast %1 : B to A
that is achieved by combining the folding with the existing "A to A" cast
elimination.