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(rust): overrides should only check full segments #3668

Merged
merged 1 commit into from
Mar 8, 2022

Conversation

syphar
Copy link
Contributor

@syphar syphar commented Feb 27, 2022

Description

Fix fixes a bug introduced in #3359, an override for ~/some/folder was also used for ~/some/folder_with_suffix. Not the first time that the difference of Path::starts_with and str::starts_with bites someone (Path::starts_with only matches full segments).

How Has This Been Tested?

  • I have tested using MacOS
  • I have tested using Linux
  • I have tested using Windows

Checklist:

  • I have updated the documentation accordingly.
  • I have updated the tests accordingly.

@syphar
Copy link
Contributor Author

syphar commented Feb 27, 2022

it would be awesome if someone could test this on windows, @davidkna perhaps?

src/modules/rust.rs Outdated Show resolved Hide resolved
src/modules/rust.rs Outdated Show resolved Hide resolved
@syphar syphar mentioned this pull request Mar 8, 2022
Copy link
Member

@davidkna davidkna left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chipbuster
Copy link
Contributor

The ninja type-change from variable shadowing. Haven't seriously thought about that one in a while.

Thanks @syphar for the fix and for getting this moving!

1 similar comment
@chipbuster
Copy link
Contributor

The ninja type-change from variable shadowing. Haven't seriously thought about that one in a while.

Thanks @syphar for the fix and for getting this moving!

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.

None yet

3 participants