mirror of
https://github.com/exoticorn/curlywas.git
synced 2026-01-20 11:46:43 +01:00
first running uw8 module
This commit is contained in:
@@ -66,9 +66,16 @@ fn import(s: &str) -> IResult<ast::Import> {
|
||||
map(
|
||||
preceded(
|
||||
ws(tag("global")),
|
||||
pair(identifier, preceded(ws(char(':')), type_)),
|
||||
pair(
|
||||
pair(opt(ws(tag("mut"))), identifier),
|
||||
preceded(ws(char(':')), type_),
|
||||
),
|
||||
),
|
||||
|(name, type_)| ast::ImportType::Variable { name, type_ },
|
||||
|((mutable, name), type_)| ast::ImportType::Variable {
|
||||
name,
|
||||
type_,
|
||||
mutable: mutable.is_some(),
|
||||
},
|
||||
),
|
||||
))(s)?;
|
||||
let (s, _) = ws(char(';'))(s)?;
|
||||
|
||||
Reference in New Issue
Block a user