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(util): properly escape breakat #4597

Merged
merged 1 commit into from
Apr 10, 2023
Merged

Conversation

Cnly
Copy link
Contributor

@Cnly Cnly commented Apr 8, 2023

In coc#string#content_height, coc uses the breakat option to determine where to break a line when it's too long. However, the option value is not properly escaped.

For example, set breakat=\ !@-+;:,./? can lead to request error on "nvim_call_function" - Vim(for):E944: Reverse range in character class when lines need to be broken. In this case, the generated pattern is [ !@-+;:,./?]\zs where @-+ is a "reverse range." The fix is to escape - as well.

@fannheyward fannheyward merged commit 43f4daa into neoclide:master Apr 10, 2023
@Cnly Cnly deleted the patch-1 branch April 10, 2023 11:23
chemzqm added a commit that referenced this pull request Jul 26, 2023
3dc6153 Correct spelling `resutl` to `result` (#4711)
3d14e72 chore(deps): bump word-wrap from 1.2.3 to 1.2.4 (#4706)
2280f9a chore(deps): bump semver from 7.5.0 to 7.5.2 (#4685)
1df60fc docs: fix wrong prefix of CocList command options, ref commit 1d3b424 (#4631)
537f12b fix(rpc): fix unknown function error (#4675)
2a0e554 feat(ci): test with nvim nightly (#4661)
edcc376 chore(README): improve mappings (#4510)
0df7380 fix(notify): use nvim_buf_set_lines for nvim (#4542)
5704b37 chore(exception): typo workspaceContains (#4545)
19c782e chore(yarn): upgrade dev-dependencies (#4627)
e51a7cd fix(list): fix opening an empty buffer in the help action of the extensions (#4652)
3014125 feat: add coc.preferences.tagDefinitionTimeout (#4601)
43f4daa fix(util): properly escape breakat (#4597)
628f08a fix: hide list correctly on vim (#4584)
94dc105 fix(api): Fix Buffer.getVar() for non-current buffer (#4569)
b28b8dc fix(util): patchLine, byte aligned (#4526)
79e9e04 Fix typos and grammatical errors (#4521)
59a942d docs: fix typo termainal -> terminal (#4514)
8c0d3ef fix(semanticTokens): make indexing of highlight groups more consistent (#4500)
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

2 participants