Temporarily turn on unicode-lines

Ropey's non-unicode lines impl has some bugs still
This commit is contained in:
Blaž Hrastnik 2022-03-17 10:52:14 +09:00
parent 16e2b2e36b
commit 2376fc875e
No known key found for this signature in database
GPG Key ID: 1238B9C4AD889640
3 changed files with 7 additions and 1 deletions

View File

@ -11,6 +11,7 @@ homepage = "https://helix-editor.com"
include = ["src/**/*", "README.md"] include = ["src/**/*", "README.md"]
[features] [features]
default = ["unicode-lines"]
unicode-lines = ["ropey/unicode_lines"] unicode-lines = ["ropey/unicode_lines"]
[dependencies] [dependencies]

View File

@ -91,7 +91,10 @@ mod test {
#[test] #[test]
fn test_categorize() { fn test_categorize() {
const EOL_TEST_CASE: &str = "\n\r\u{000B}\u{000C}\u{0085}\u{2028}\u{2029}"; #[cfg(not(feature = "unicode-lines"))]
const EOL_TEST_CASE: &str = "\n";
#[cfg(feature = "unicode-lines")]
const EOL_TEST_CASE: &str = "\n\u{000B}\u{000C}\u{0085}\u{2028}\u{2029}";
const WORD_TEST_CASE: &str = "_hello_world_あいうえおー1234567890"; const WORD_TEST_CASE: &str = "_hello_world_あいうえおー1234567890";
const PUNCTUATION_TEST_CASE: &str = const PUNCTUATION_TEST_CASE: &str =
"!\"#$%&\'()*+,-./:;<=>?@[\\]^`{|}~!”#$%&’()*+、。:;<=>?@「」^`{|}~"; "!\"#$%&\'()*+,-./:;<=>?@[\\]^`{|}~!”#$%&’()*+、。:;<=>?@「」^`{|}~";

View File

@ -16,6 +16,8 @@ build = true
app = true app = true
[features] [features]
default = ["unicode-lines"]
unicode-lines = ["helix-core/unicode-lines"]
[[bin]] [[bin]]
name = "hx" name = "hx"