anchor.diff:              override x.Compute(token) =
                   reader.GetOperations token
                       |> HDeltaSet.toSeq
  -                    |> Seq.map (fun d ->
  +                    |> Seq.choose (fun d ->
                           match d with
                               | Add(1,v) -> 
                                   let i = indices.Invoke v
  -                                i, Set v
  +                                Some (i, Set v)
                               | Rem(1,v) ->
  -                                let i = indices.Revoke v
  -                                i, Remove
  +                                match indices.Revoke v with
  +                                    | Some i -> Some(i, Remove)
  +                                    | None -> None
                               | _ ->
                                   failwith ""
                       )
  
positive.code: 
                                  match oldB with
                                      | Some oldB ->
                                          let oi = indices.Revoke oldB
                                          PDeltaList.ofList [oi, Remove; i, Set v]
                                      | None ->
                                          PDeltaList.single i (Set v)
  
  
  
                              | Remove ->
                                  let b = mapping.Revoke(ii)
                                  let i = indices.Revoke b
                                  PDeltaList.single i Remove
                      )
          
          type ListSortWithReader<'a>(scope : Ag.Scope, input : alist<'a>, comparer : IComparer<'a>) =
  
negative.code:             override x.Compute(token) =
                  reader.GetOperations token 
                      |> HDeltaSet.toSeq
                      |> Seq.choose (fun d ->
                          match d with
                              | Add(1,v) -> 
                                  let k = mapping.Invoke v
                                  let i = indices.Invoke k
                                  Some (i, Set v)
                              | Rem(1,v) ->
                                  let k = mapping.Revoke v
                                  let i = indices.Revoke k
                                  match i with
                                      | Some i -> Some (i, Remove)
                                      | None -> None
                              | _ ->
                                  failwith ""
                      )
  