Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typo in Compiler.cs #17285

Merged
merged 1 commit into from May 10, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/System.Management.Automation/engine/parser/Compiler.cs
Expand Up @@ -1064,7 +1064,7 @@ internal static Expression CallSetVariable(Expression variablePath, Expression r

internal Expression GetAutomaticVariable(VariableExpressionAst varAst)
{
// Generate, in psuedo code:
// Generate, in pseudo code:
//
// return (localsTuple.IsValueSet(tupleIndex)
// ? localsTuple.ItemXXX
Expand All @@ -1074,7 +1074,7 @@ internal Expression GetAutomaticVariable(VariableExpressionAst varAst)
//
// * $PSCmdlet - always set if the script uses cmdletbinding.
// * $_ - always set in process and end block, otherwise need dynamic checks.
// * $this - can never know if it's set, always need above psuedo code.
// * $this - can never know if it's set, always need above pseudo code.
// * $input - also can never know - it's always set from a command process, but not necessarily set from ScriptBlock.Invoke.
//
// These optimizations are not yet performed.
Expand Down Expand Up @@ -3907,7 +3907,7 @@ private Expression GetRedirectedExpression(CommandExpressionAst commandExpr, boo
// funcContext.OutputPipe = oldPipe;
// }
//
// In the above psuedo-code, any of {outputFileRedirection, nonOutputFileRedirection, mergingRedirection} may
// In the above pseudo-code, any of {outputFileRedirection, nonOutputFileRedirection, mergingRedirection} may
// not exist, but the order is preserved, so that file redirections go before merging redirections (so that
// funcContext.OutputPipe has the correct value when setting up merging.)
//
Expand Down Expand Up @@ -5178,7 +5178,7 @@ public object VisitCatchClause(CatchClauseAst catchClauseAst)
// If the automatic var has no value in the current frame, then we set the variable's value to $null
// after leaving the stmt.
//
// The psuedo-code:
// The pseudo-code:
//
// try {
// oldValue = (localSet.Get(automaticVar)) ? locals.ItemNNN : null;
Expand Down