anchor.diff:  module RuleSet =
     type Cache =
       {rules: ConcurrentDictionary<Type, array<Rule>>
  -     trees: ConcurrentDictionary<HashEqSet<Type>, TyTree<Rule>>}
  +     trees: ConcurrentDictionary<HashEqSet<Type>, TyTree<Rule>>
  +     lastFailures: Queue<string * list<Ty>>
  +     mutable limitReached: bool}
     type RuleSet =
       {cache: Cache
        rules: HashEqSet<Type>
  
positive.code:                       Seq.singleton (result, objEnv, tyEnv)
                      | parTy::parTys ->
                        Ty.resolve tyEnv parTy
                        |> tryGen limit reached rules objEnv tyEnv (ty::stack)
                        |> Seq.collect (fun (result, objEnv, tyEnv) ->
                           let rec inner resolvedArgs rules objEnv = function
                             | [] ->
  
negative.code:                   else
                      match Ty.toMonoType ty with
                       | None ->
                         addFailurePath rules stack ty "Infinite derivation"
                         Seq.empty
                       | Some monoTy ->
                         match HashEqMap.tryFind monoTy objEnv with
                          | Some o ->
                            Seq.singleton (Value (monoTy, o), objEnv, tyEnv)
                          | None ->
                            let recTy = App (Def typedefof<Rec<_>>, [|ty|])
                            match
                              recTy
                              |> tryGen limit rules objEnv tyEnv (ty::stack)
                              |> Seq.tryPick (fun (result, objEnv, tyEnv) ->
                                 match result with
                                  | Ruled _ -> None
                                  | Value (monoRecTy, recO) ->
                                    match recO with
                                     | :? IRecObj as recO' ->
                                       let o = recO'.GetObj ()
                                       Some (Value (monoTy, o),
                                             objEnv
                                             |> HashEqMap.add monoRecTy recO
                                             |> addObj monoTy o,
                                             tyEnv)
                                     | _ ->
                                       failwith "Bug") with
                             | None ->
                               addFailurePath rules stack recTy "No Rec rule"
                               Seq.empty
                             | Some x ->
                               Seq.singleton x
                   else
                     match parTys with
                      | [] ->
  