Fix invalid comparison for Class::Decoration in is_equal_to

This commit is contained in:
Guillaume Gomez 2022-08-19 14:35:15 +02:00
parent 9c20b2a8cc
commit 934d259b8c

View File

@ -291,8 +291,8 @@ impl Class {
match (self, other) {
(Self::Self_(_), Self::Self_(_))
| (Self::Macro(_), Self::Macro(_))
| (Self::Ident(_), Self::Ident(_))
| (Self::Decoration(_), Self::Decoration(_)) => true,
| (Self::Ident(_), Self::Ident(_)) => true,
(Self::Decoration(c1), Self::Decoration(c2)) => c1 == c2,
(x, y) => x == y,
}
}