KEMBAR78
Fix completion of variables assigned inside Do loops by MartinGC94 · Pull Request #25076 · PowerShell/PowerShell · GitHub
Skip to content

Conversation

@MartinGC94
Copy link
Contributor

PR Summary

Fixes completion of variables assigned inside Do loops while the variable to complete is also inside the Do loop. For example:

    do
    {
        $Test = ls
        $Tes<Tab>
    }
    until ($x -gt 0)

This would not complete as it would visit the until condition before the statement block, and because it's after the cursor it would stop visiting the remaining asts.

PR Context

PR Checklist

@iSazonov
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

MartinGC94 and others added 3 commits February 25, 2025 11:03
@iSazonov iSazonov added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label Feb 25, 2025
@iSazonov

This comment was marked as outdated.

@azure-pipelines

This comment was marked as outdated.

@iSazonov iSazonov self-assigned this Feb 26, 2025
@iSazonov iSazonov merged commit c64a636 into PowerShell:master Feb 26, 2025
39 of 41 checks passed
@microsoft-github-policy-service
Copy link
Contributor

microsoft-github-policy-service bot commented Feb 26, 2025

📣 Hey @MartinGC94, how did we do? We would love to hear your feedback with the link below! 🗣️

🔗 https://aka.ms/PSRepoFeedback

@MartinGC94 MartinGC94 deleted the DoLoopsVarCompletion branch February 28, 2025 10:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants