Create spaced list when values are adjacent
This commit is contained in:
parent
fba6f2eb73
commit
c4d365a124
@ -142,7 +142,7 @@ impl Value {
|
||||
};
|
||||
Ok(Value::BinaryOp(Box::new(left), op, Box::new(right)))
|
||||
}
|
||||
_ if whitespace => {
|
||||
_ => {
|
||||
devour_whitespace_or_comment(toks);
|
||||
let right = match Self::from_tokens(toks, scope) {
|
||||
Ok(x) => x,
|
||||
@ -150,10 +150,6 @@ impl Value {
|
||||
};
|
||||
Ok(Value::List(vec![left, right], ListSeparator::Space))
|
||||
}
|
||||
_ => {
|
||||
dbg!(&next.kind);
|
||||
todo!("unimplemented token in value")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -345,3 +345,8 @@ test!(
|
||||
"a {\n color: type-of(#foo);\n}\n",
|
||||
"a {\n color: string;\n}\n"
|
||||
);
|
||||
test!(
|
||||
adjacent_strings_get_spaced,
|
||||
"a {\n color: \"f\"foo;\n}\n",
|
||||
"a {\n color: \"f\" foo;\n}\n"
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user