Fix fromSlice signature and compare the slices.