Skip to content

Commit

Permalink
Only print evaluate requests in REPL context (#1334)
Browse files Browse the repository at this point in the history
This PR fixes the EvaluateRequest with an -exec command and assign the return protocol with the correct Value.

This causes the DebugConsole in VS Code to show the output as a REPL output (gray) instead of an engine output (blue).
  • Loading branch information
WardenGnaw authored Aug 10, 2022
1 parent 6118510 commit 93c8040
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/MIDebugEngine/Engine.Impl/Variables.cs
Original file line number Diff line number Diff line change
Expand Up @@ -524,13 +524,8 @@ internal async Task Eval(uint radix, enum_EVALFLAGS dwFlags = 0, DAPEvalFlags dw
string consoleResults = null;

consoleResults = await MIDebugCommandDispatcher.ExecuteCommand(consoleCommand, _debuggedProcess, ignoreFailures: true);
Value = String.Empty;
Value = consoleResults;
this.TypeName = null;

if (!String.IsNullOrEmpty(consoleResults))
{
_debuggedProcess.WriteOutput(consoleResults);
}
}
else
{
Expand Down

0 comments on commit 93c8040

Please sign in to comment.