Syntax: Tuples as ()
This commit is contained in:
@@ -97,7 +97,7 @@ generics = { "<" ~ (generic ~ ("," ~ generic)*)? ~ ">" }
|
|||||||
// ======================================================
|
// ======================================================
|
||||||
|
|
||||||
tuple_type = {
|
tuple_type = {
|
||||||
"[" ~ (type_expr ~ ("," ~ type_expr)*)? ~ ","? ~ "]"
|
"(" ~ (type_expr ~ ("," ~ type_expr)*)? ~ ","? ~ ")"
|
||||||
}
|
}
|
||||||
|
|
||||||
path_type = {
|
path_type = {
|
||||||
@@ -142,11 +142,11 @@ multi_pat_template = _{
|
|||||||
}
|
}
|
||||||
|
|
||||||
tuple_pattern = {
|
tuple_pattern = {
|
||||||
"[" ~ (pattern | etc_pattern) ~ "," ~ multi_pat_template ~ "]"
|
"(" ~ (pattern | etc_pattern) ~ "," ~ multi_pat_template ~ ")"
|
||||||
}
|
}
|
||||||
|
|
||||||
named_tuple_pattern = {
|
named_tuple_pattern = {
|
||||||
static_path ~ "[" ~ multi_pat_template ~ "]"
|
static_path ~ "(" ~ multi_pat_template ~ ")"
|
||||||
}
|
}
|
||||||
|
|
||||||
struct_destruct = {
|
struct_destruct = {
|
||||||
|
|||||||
@@ -1,5 +1,3 @@
|
|||||||
fn Result<[], String> main() {
|
fn void main() {
|
||||||
println!("running common tests...");
|
println!("running common tests...");
|
||||||
|
|
||||||
Ok(())
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user