summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2022-08-06 07:38:24 +0300
committerLars Wirzenius <liw@liw.fi>2022-08-06 07:39:01 +0300
commitbe85bae2e516ce3b2b7874e94e5bb4fea6c30754 (patch)
tree14136e465198ea574f85d696698067aab0dc7a90
parent862525b459be669e7c5faf40cbdd8406dde1baf9 (diff)
downloadriki-be85bae2e516ce3b2b7874e94e5bb4fea6c30754.tar.gz
fix: allow "words" to include colons
Sponsored-by: author
-rw-r--r--src/token.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/token.rs b/src/token.rs
index 83e6c41..5109ce1 100644
--- a/src/token.rs
+++ b/src/token.rs
@@ -33,7 +33,7 @@ impl Default for TokenPatterns {
fn default() -> Self {
Self {
plain: Regex::new(r#"(?P<value>[^\[]+)"#).unwrap(),
- word: Regex::new(r#"[-._/[:alpha:][:digit:]]+"#).unwrap(),
+ word: Regex::new(r#"[-.:_/[:alpha:][:digit:]]+"#).unwrap(),
spaces: Regex::new(r#"([[:space:]]|\n)+"#).unwrap(),
single_quoted: Regex::new(r#""(?P<value>(.|\n)*?)""#).unwrap(),
triple_quoted: Regex::new(r#""""(?P<value>(.|\n)*?)""""#).unwrap(),