Constify the input slices to accept both &mut and &imm