anchor.diff:        mk (A.PatApp(mk (A.PatName fv.fv_name.v), args))
   
       | Pat_var v -> 
  -      (* both A.PatTvar and A.PatVar are desugared to S.Pat_var, only resugar back as PatVar*)
  +      // both A.PatTvar and A.PatVar are desugared to S.Pat_var. A PatTvar in the original file coresponds
  +      // to some type variable which is implicitly bound to the enclosing toplevel declaration. 
  +      // When resugaring it will be just a normal (explicitly bound) variable.
         begin match string_to_op v.ppname.idText with
          | Some op -> mk (A.PatOp op)
          | None -> mk (A.PatVar (bv_as_unique_ident v, None))
  
positive.code:             | hd :: tl -> last tl
              | _ -> failwith "Empty list." in
            let body, _ = last args in
            let binders, body = match (SS.compress body).n with
              | Tm_abs(xs, body, _) ->
                  let xs, body = SS.open_term xs body in
                  let xs = xs |> List.map (fun (b, qual) -> resugar_bv_as_binder b t.pos) in 
                  let body = resugar_term body in
                  xs, body
              | _ ->
                [], resugar_term body in
            mk (A.Sum(binders, body))
  
          (*| Some field_projector when (U.field_projector_contains_constructor field_projector) ->
            (* get the field name from the fvar *)
  
negative.code:       | Meta_labeled (l, _, p) ->
            mk (A.Labeled(resugar_term e, l, p))
        | Meta_desugared i -> 
            resugar_meta_desugared i        
        end
      
      | Tm_unknown _ -> mk A.Wild
  