labath added a comment.

Jim's comment definitely makes sense. If we happen to not use pretty-printer 
for the unique_ptr, it will not behave as a pointer-like object, and it should 
be formatted as a normal struct (I have no idea how much of a challenge it 
would be to implement it that way).



================
Comment at: source/DataFormatters/ValueObjectPrinter.cpp:515
   const bool is_ptr = IsPtr();
+  const bool is_ref_or_ptr_like = IsRef() || IsPointerLikeObject();
   const bool is_uninit = IsUninitialized();
----------------
Is there are reason you are bundling the is-pointer-like with the is-ref flag 
instead of the is-ptr one (which would be more logical)? If there is one it 
certainly isn't obvious.


================
Comment at: source/Target/StackFrame.cpp:637
+        } else {
+          error.SetErrorStringWithFormat(
+              "Failed to dereference a pointer like object: %s",
----------------
SetErrorStringWithFormatv (and then you can drop the .AsCString from the 
deref_error).


https://reviews.llvm.org/D30272



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to