From 5c11aa72239ecbdd9577f027bdc7e9468d68414e Mon Sep 17 00:00:00 2001 From: Laurenz Date: Tue, 4 Feb 2020 11:22:00 +0100 Subject: =?UTF-8?q?Adapt=20for=20tonty=20and=20fix=20a=20few=20bugs=20?= =?UTF-8?q?=F0=9F=9A=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/syntax/func/values.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/syntax/func/values.rs') diff --git a/src/syntax/func/values.rs b/src/syntax/func/values.rs index 18d451e3..d2b54a0b 100644 --- a/src/syntax/func/values.rs +++ b/src/syntax/func/values.rs @@ -87,7 +87,7 @@ value!(ScaleSize, "number or size", /// A value type that matches [`Expr::Ident`] and [`Expr::Str`] and implements /// `Into`. -pub struct StringLike(String); +pub struct StringLike(pub String); value!(StringLike, "identifier or string", Expr::Ident(Ident(s)) => StringLike(s), @@ -117,7 +117,7 @@ impl From for String { /// [func: size=default] => None /// [func: size=2cm] => Some(Size::cm(2.0)) /// ``` -pub struct Defaultable(Option); +pub struct Defaultable(pub Option); impl Value for Defaultable { fn parse(expr: Spanned) -> Result { -- cgit v1.2.3