jingham marked an inline comment as done.
jingham added inline comments.

================
Comment at: lldb/bindings/python/python-wrapper.swig:390
+  if (PyErr_Occurred()) {
+    printf("Error occured for call to %s.\n",
+           method_name);
----------------
mib wrote:
> If we passed a `Status&` instead of a `bool&` we would be able to get that 
> error message in lldb.
GetDescription doesn't end up returning a Status, just a bool saying whether 
anything got added.  So even if I added a Status here, there would be no place 
for it to go.


================
Comment at: lldb/include/lldb/Interpreter/ScriptInterpreter.h:320
+                                       lldb_private::Stream *stream,
+                                       bool &script_error) {
+    script_error = true;
----------------
mib wrote:
> For Scripted Process, I pass a `Status&` argument which can hold an error 
> message for better debugging. By doing so, you can also return 
> `Status.Success()`
There isn't any place to return an error along the GetStopDescription path 
above us.  That API just returns a bool saying whether you added information to 
the stream.  So returning just a bool at this layer mirrors its use better.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D149692/new/

https://reviews.llvm.org/D149692

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

Reply via email to