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 vi_yank or vi_delete_meta copies nil bug #726

Merged
merged 1 commit into from
Jun 18, 2024

Conversation

tompng
Copy link
Member

@tompng tompng commented Jun 12, 2024

In vi command mode, and when cursor is at the beginning of the line, dhp or yhp will copy a nil to @vi_clipboard and tries to paste nil as a text, and raises:

lib/reline/line_editor.rb:2348:in `vi_paste_next': undefined method `size' for nil (NoMethodError)
    if @vi_clipboard.size > 0

@tompng tompng added the bug Something isn't working label Jun 12, 2024
Copy link
Member

@ima1zumi ima1zumi left a comment

Choose a reason for hiding this comment

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

👍

@ima1zumi ima1zumi merged commit 46b30b0 into ruby:master Jun 18, 2024
40 checks passed
@tompng tompng deleted the vi_nil_copy_fix branch June 18, 2024 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

Successfully merging this pull request may close these issues.

2 participants