mirror of
https://github.com/servo/servo
synced 2026-04-29 10:57:43 +02:00
Generate PartialEq automatically
This commit is contained in:
@@ -2339,6 +2339,12 @@ impl IDLInterface for %(name)s {
|
||||
%(check)s
|
||||
}
|
||||
}
|
||||
|
||||
impl PartialEq for %(name)s {
|
||||
fn eq(&self, other: &%(name)s) -> bool {
|
||||
self as *const %(name)s == &*other
|
||||
}
|
||||
}
|
||||
""" % {'check': check, 'name': name}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user