but these are not legal expressions in Rust. A range with a lower bound cannot be the upper bound of another range, and a range with an upper bound cannot be the lower bound of another range.
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
--> src/main.rs:2:19
|
2 | let _ = .. () ..;
| ^^ expected one of `.`, `;`, `?`, `else`, or an operator
error: expected one of `.`, `;`, `?`, `else`, or an operator, found `..`
--> src/main.rs:3:22
|
3 | let _ = () .. () ..;
| ^^ expected one of `.`, `;`, `?`, `else`, or an operator
Previously, syn incorrectly accepted
.. $e ..
as:and
$e .. $e ..
as:but these are not legal expressions in Rust. A range with a lower bound cannot be the upper bound of another range, and a range with an upper bound cannot be the lower bound of another range.