Skip to content

Conversation

@iSazonov
Copy link
Collaborator

@iSazonov iSazonov commented Oct 19, 2018

PR Summary

Replace string operations on char ones by using overloads like StartsWith(char) and EndsWith(char).

It speeds up path operations in filesystem provider and globbing.

PR Checklist

@iSazonov iSazonov added the Issue-Code Cleanup the issue is for cleaning up the code with no impact on functionality label Oct 19, 2018
@iSazonov iSazonov self-assigned this Oct 19, 2018
@anmenaga
Copy link

I'm curious, what was the reason why Path Separator was a string (rather than a char)?

@SteveL-MSFT
Copy link
Member

@anmenaga .NET Framework only has overload for string, .NET Core added overload for char

@iSazonov iSazonov merged commit ecb467c into PowerShell:master Oct 31, 2018
@iSazonov iSazonov deleted the cleanup-defaultpathseparator branch October 31, 2018 03:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Issue-Code Cleanup the issue is for cleaning up the code with no impact on functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants