reshape for sharedarray

Allows reshaping of a SharedArray. The reshaped array refers to the same underlying shared memory and has the same distribution across processes as the original.