let object_of_root = function 
        Cvar x -> Some (object_of x.vtype) 
      | Lvar lv ->
          begin
            match lv.lv_type with 
              | Ctype t -> Some (object_of t)
              | _ -> None
          end