mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-07-01 18:51:04 +02:00
fix(dynamic string): ironvar parser being too greedy
This commit is contained in:
parent
bfec31254f
commit
4d9d78f4ca
1 changed files with 1 additions and 1 deletions
|
@ -155,7 +155,7 @@ fn parse_variable(chars: &[char]) -> (DynamicStringSegment, usize) {
|
||||||
let str = chars
|
let str = chars
|
||||||
.iter()
|
.iter()
|
||||||
.skip(1)
|
.skip(1)
|
||||||
.take_while(|&c| !c.is_whitespace())
|
.take_while(|&c| c.is_ascii_alphanumeric() || c == &'_' || c == &'-')
|
||||||
.collect::<String>();
|
.collect::<String>();
|
||||||
|
|
||||||
let len = str.chars().count() + SKIP_HASH;
|
let len = str.chars().count() + SKIP_HASH;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue