Skip to content

Fix function keyword syntax #1

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

Closed
wants to merge 1 commit into from
Closed

Conversation

Jaykul
Copy link
Owner

@Jaykul Jaykul commented Nov 23, 2015

This fixes a longstanding bug highlighting code like:

# This is ok
Test-Highlight -Something StringValue
# This is not
Test-Highlight -TestFunction StringValue
# and it breaks this:
Test-Highlight -Something StringValue

I also fixed scope on function names, like:

function Test-Thing { Get-Command $VariableName }
# the function name should be highlighted as above, and both "global"s should be the same...
function global:Test-Thing { Get-Command $global:VariableName }
Function LOCAL:Test-Thing { Get-Command $local:VariableName }
FUNCTION script:Test-Thing { Get-Command $script:VariableName }

Same change as SublimeText/PowerShell#137

Avoid matching "function" at the end of other words
Fix highlighting of scope keywords
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant