================
@@ -181,7 +181,17 @@ void EvaluateRequestHandler::operator()(
         expression = dap.last_nonempty_var_expression;
       else
         dap.last_nonempty_var_expression = expression;
+    } else {
+      // If this isn't a REPL context, trim leading pointer/reference 
characters
+      // to ensure we return the actual value of the expression.
----------------
jimingham wrote:

Since people have to voluntarily put something in a watch panel, then in that 
case we should even run it as an expression.  If somebody actually puts `i++` 
in a watch window, presumably they meant for it to increment every time they 
stepped.
We had a silly bug in gdbtk way back in the day where we if you moused over a 
selection we would run the selection  as an expression.  But lots of people 
seem to select expressions so that they can focus on just the part they 
selected.  As you can imagine, that went poorly.
The main thing - for me - is not to always have running expressions be a 
distinct gesture.

https://github.com/llvm/llvm-project/pull/146773
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to