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: enable remapping of numbers #2793

Merged
merged 3 commits into from
Jun 30, 2018
Merged

fix: enable remapping of numbers #2793

merged 3 commits into from
Jun 30, 2018

Conversation

jpoon
Copy link
Member

@jpoon jpoon commented Jun 29, 2018

What this PR does / why we need it:

  • This PR addresses issue Bug: Remapping Numbers (0-9) #2759 to enable remapping of numbers (e.g. remapping 0 to ^). Although this PR enables the remapping of ALL numbers, I don't see a real scenario where somebody would want to remap numbers 1-9 as that would override the default count behaviour for motions and operators.
  • Adds more checks for remapped configurations ignoring all that are invalid (e.g. duplicate or missing an after or a command)

Which issue(s) this PR fixes

#2759

Special notes for your reviewer:

@jpoon jpoon force-pushed the remapper branch 2 times, most recently from dd05f75 to 13c49b9 Compare June 29, 2018 19:41
@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@xconverge
Copy link
Member

Did you experience the crazy slowdown when reproducing the issue before fixing it?

@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@jpoon
Copy link
Member Author

jpoon commented Jun 30, 2018

Nope, didn't see any slowdown. This PR should slightly improve perf. Put the remappings into a map so it should be O(1) instead of having to iterate through all the remappings to see if they match.

@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
@VSCodeVim VSCodeVim deleted a comment from TravisBuddy Jun 30, 2018
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.

2 participants