Fix highlighting of const patterns

This commit is contained in:
Aleksey Kladov 2020-02-28 16:36:14 +01:00
parent 209eb32796
commit 5ebfcb9cb7
5 changed files with 60 additions and 15 deletions

View file

@ -50,12 +50,19 @@ fn main() {
y;
}
enum E<X> {
V(X)
enum Option<T> {
Some(T),
None,
}
use Option::*;
impl<X> E<X> {
fn new<T>() -> E<T> {}
impl<T> Option<T> {
fn and<U>(self, other: Option<U>) -> Option<(T, U)> {
match other {
None => todo!(),
Nope => Nope,
}
}
}
"#
.trim(),