Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Bigword movement doesn't handle non-print non-blank characters very well #7328

Copy link
Copy link

Description

@lilyball
Issue body actions

Bigword movement uses std::iswblank(c) and std::iswgraph(c) in its implementation, and seems to make the assumption that any character is either blank or graph (or a control character which it doesn't care about). But in the BMP alone there are 6801 codepoints (on my machine running macOS 10.15.6) that are neither blank nor graph or control. Some of these are reserved codepoints, but many are not. For example, Σ (U+03A3 GREEK CAPITAL LETTER SIGMA). Given this, the implementation should probably be using !std::iswblank(c) anywhere it uses std::iswgraph(c).

For that matter, newlines are whitespace but they aren't blank, which means bigword movement stops on every newline, which seems odd. So it should probably be using std::iswspace instead of std::iswblank (the former includes 8 characters the latter doesn't).

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.