Skip to content

Commit bc141fd

Browse files
committed
Cleaned up some build issues in Release config and cleaned up my coding style a bit.
1 parent fca9035 commit bc141fd

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

src/PowerShellEditorServices/Debugging/DebugService.cs

+8-4
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
44
//
55

6-
using Microsoft.PowerShell.EditorServices.Utility;
76
using System;
87
using System.Collections.Generic;
98
using System.Linq;
109
using System.Management.Automation;
1110
using System.Threading.Tasks;
11+
using Microsoft.PowerShell.EditorServices.Utility;
1212

1313
namespace Microsoft.PowerShell.EditorServices
1414
{
@@ -323,8 +323,11 @@ private async Task FetchStackFramesAndVariables()
323323
private async Task FetchGlobalAndScriptVariables()
324324
{
325325
// Retrieve globals first as script variable retrieval needs to search globals.
326-
this.globalScopeVariables = await FetchVariableContainer(VariableContainerDetails.GlobalScopeName, null);
327-
this.scriptScopeVariables = await FetchVariableContainer(VariableContainerDetails.ScriptScopeName, null);
326+
this.globalScopeVariables =
327+
await FetchVariableContainer(VariableContainerDetails.GlobalScopeName, null);
328+
329+
this.scriptScopeVariables =
330+
await FetchVariableContainer(VariableContainerDetails.ScriptScopeName, null);
328331
}
329332

330333
private async Task<VariableContainerDetails> FetchVariableContainer(
@@ -392,7 +395,8 @@ private bool AddToAutoVariables(PSVariable psvariable, string scope)
392395
if (((psvariable.Options | constantAllScope) == constantAllScope) ||
393396
((psvariable.Options | readonlyAllScope) == readonlyAllScope))
394397
{
395-
if (this.globalScopeVariables.Children.ContainsKey(VariableDetails.DollarPrefix + psvariable.Name))
398+
string prefixedVariableName = VariableDetails.DollarPrefix + psvariable.Name;
399+
if (this.globalScopeVariables.Children.ContainsKey(prefixedVariableName))
396400
{
397401
return false;
398402
}

src/PowerShellEditorServices/Debugging/StackFrameDetails.cs

+3
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ public class StackFrameDetails
5050
/// <param name="callStackFrame">
5151
/// The original CallStackFrame instance from which details will be obtained.
5252
/// </param>
53+
/// <param name="autoVariables">
54+
/// A variable container with all the filtered, auto variables for this stack frame.
55+
/// </param>
5356
/// <param name="localVariables">
5457
/// A variable container with all the local variables for this stack frame.
5558
/// </param>

0 commit comments

Comments
 (0)