Merge pull request #1673 from Pauan/web-sys-partial-eq

Adding in PartialEq and Eq to web-sys types
This commit is contained in:
Alex Crichton 2019-07-19 08:49:52 -05:00 committed by GitHub
commit 55b486ad78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -14,6 +14,8 @@ fn element() {
*/
let element = new_div();
assert_eq!(element, element);
assert_eq!(element.prefix(), None, "Shouldn't have a prefix");
assert_eq!(element.local_name(), "div", "Should have a div local name");
assert_eq!(element.tag_name(), "DIV", "Should be a div tag");

View File

@ -541,7 +541,7 @@ impl<'src> FirstPassRecord<'src> {
let mut doc_comment = Some(format!("The `{}` object\n\n{}", name, mdn_doc(name, None),));
let mut attrs = Vec::new();
attrs.push(syn::parse_quote!( #[derive(Debug, Clone)] ));
attrs.push(syn::parse_quote!( #[derive(Debug, Clone, PartialEq, Eq)] ));
self.add_deprecated(data, &mut attrs);
let mut import_type = ast::ImportType {
vis: public(),