diff --git a/components/layout_thread/lib.rs b/components/layout_thread/lib.rs index 4e407e2146e..970896f3864 100644 --- a/components/layout_thread/lib.rs +++ b/components/layout_thread/lib.rs @@ -101,6 +101,7 @@ use std::marker::PhantomData; use std::mem as std_mem; use std::ops::{Deref, DerefMut}; use std::process; +use std::slice; use std::sync::{Arc, Mutex, MutexGuard}; use std::sync::atomic::{AtomicUsize, Ordering}; use std::sync::mpsc::{Receiver, Sender, channel}; @@ -117,7 +118,7 @@ use style::selector_parser::SnapshotMap; use style::servo::restyle_damage::{REFLOW, REFLOW_OUT_OF_FLOW, REPAINT, REPOSITION, STORE_OVERFLOW}; use style::shared_lock::{SharedRwLock, SharedRwLockReadGuard, StylesheetGuards}; use style::stylearc::Arc as StyleArc; -use style::stylesheets::{Origin, Stylesheet, UserAgentStylesheets}; +use style::stylesheets::{Origin, Stylesheet, StylesheetInDocument, UserAgentStylesheets}; use style::stylist::{ExtraStyleData, Stylist}; use style::thread_state; use style::timer::Timer; @@ -417,6 +418,17 @@ fn add_font_face_rules(stylesheet: &Stylesheet, } } +#[derive(Clone)] +struct StylesheetIterator<'a>(slice::Iter<'a, StyleArc>); + +impl<'a> Iterator for StylesheetIterator<'a> { + type Item = &'a Stylesheet; + + fn next(&mut self) -> Option { + self.0.next().map(|s| &**s) + } +} + impl LayoutThread { /// Creates a new `LayoutThread` structure. fn new(id: PipelineId, @@ -1146,7 +1158,7 @@ impl LayoutThread { marker: PhantomData, }; let needs_dirtying = self.stylist.update( - data.document_stylesheets.iter(), + StylesheetIterator(data.document_stylesheets.iter()), &guards, Some(ua_stylesheets), data.stylesheets_changed, diff --git a/components/script/dom/csskeyframesrule.rs b/components/script/dom/csskeyframesrule.rs index 469f9b7d026..888f945caa7 100644 --- a/components/script/dom/csskeyframesrule.rs +++ b/components/script/dom/csskeyframesrule.rs @@ -82,7 +82,13 @@ impl CSSKeyframesRuleMethods for CSSKeyframesRule { // https://drafts.csswg.org/css-animations/#dom-csskeyframesrule-appendrule fn AppendRule(&self, rule: DOMString) { - let rule = Keyframe::parse(&rule, self.cssrule.parent_stylesheet().style_stylesheet()); + let style_stylesheet = self.cssrule.parent_stylesheet().style_stylesheet(); + let rule = Keyframe::parse( + &rule, + &style_stylesheet.contents, + &style_stylesheet.shared_lock + ); + if let Ok(rule) = rule { let mut guard = self.cssrule.shared_lock().write(); self.keyframesrule.write_with(&mut guard).keyframes.push(rule); diff --git a/components/script/dom/cssrulelist.rs b/components/script/dom/cssrulelist.rs index d0dfe120410..28b1779be29 100644 --- a/components/script/dom/cssrulelist.rs +++ b/components/script/dom/cssrulelist.rs @@ -93,7 +93,7 @@ impl CSSRuleList { let new_rule = css_rules.insert_rule(&parent_stylesheet.shared_lock, rule, - parent_stylesheet, + &parent_stylesheet.contents, index, nested, None)?; diff --git a/components/script/dom/cssstyledeclaration.rs b/components/script/dom/cssstyledeclaration.rs index 2ef448720d6..8e17e50a8fa 100644 --- a/components/script/dom/cssstyledeclaration.rs +++ b/components/script/dom/cssstyledeclaration.rs @@ -146,7 +146,7 @@ impl CSSStyleOwner { match *self { CSSStyleOwner::Element(ref el) => window_from_node(&**el).Document().base_url(), CSSStyleOwner::CSSRule(ref rule, _) => { - (*rule.parent_stylesheet().style_stylesheet().url_data.read()).clone() + (*rule.parent_stylesheet().style_stylesheet().contents.url_data.read()).clone() } } } diff --git a/components/script/dom/cssstylesheet.rs b/components/script/dom/cssstylesheet.rs index cb378b2261a..8d42d8c7b6d 100644 --- a/components/script/dom/cssstylesheet.rs +++ b/components/script/dom/cssstylesheet.rs @@ -57,10 +57,14 @@ impl CSSStyleSheet { } fn rulelist(&self) -> Root { - self.rulelist.or_init(|| CSSRuleList::new(self.global().as_window(), - self, - RulesSource::Rules(self.style_stylesheet - .rules.clone()))) + self.rulelist.or_init(|| { + let rules = self.style_stylesheet.contents.rules.clone(); + CSSRuleList::new( + self.global().as_window(), + self, + RulesSource::Rules(rules) + ) + }) } pub fn disabled(&self) -> bool { diff --git a/components/script/dom/htmlmetaelement.rs b/components/script/dom/htmlmetaelement.rs index cc11a9d9da4..a4c22bc9a82 100644 --- a/components/script/dom/htmlmetaelement.rs +++ b/components/script/dom/htmlmetaelement.rs @@ -27,7 +27,7 @@ use style::attr::AttrValue; use style::media_queries::MediaList; use style::str::HTML_SPACE_CHARACTERS; use style::stylearc::Arc; -use style::stylesheets::{Stylesheet, CssRule, CssRules, Origin, ViewportRule}; +use style::stylesheets::{Stylesheet, StylesheetContents, CssRule, CssRules, Origin, ViewportRule}; #[dom_struct] pub struct HTMLMetaElement { @@ -103,17 +103,20 @@ impl HTMLMetaElement { let shared_lock = document.style_shared_lock(); let rule = CssRule::Viewport(Arc::new(shared_lock.wrap(translated_rule))); *self.stylesheet.borrow_mut() = Some(Arc::new(Stylesheet { - rules: CssRules::new(vec![rule], shared_lock), - origin: Origin::Author, - shared_lock: shared_lock.clone(), - url_data: RwLock::new(window_from_node(self).get_url()), - namespaces: Default::default(), + contents: StylesheetContents { + rules: CssRules::new(vec![rule], shared_lock), + origin: Origin::Author, + namespaces: Default::default(), + quirks_mode: document.quirks_mode(), + url_data: RwLock::new(window_from_node(self).get_url()), + // Viewport constraints are always recomputed on + // resize; they don't need to force all styles to be + // recomputed. + dirty_on_viewport_size_change: AtomicBool::new(false), + }, media: Arc::new(shared_lock.wrap(MediaList::empty())), - // Viewport constraints are always recomputed on resize; they don't need to - // force all styles to be recomputed. - dirty_on_viewport_size_change: AtomicBool::new(false), + shared_lock: shared_lock.clone(), disabled: AtomicBool::new(false), - quirks_mode: document.quirks_mode(), })); let doc = document_from_node(self); doc.invalidate_stylesheets(); diff --git a/components/script/stylesheet_loader.rs b/components/script/stylesheet_loader.rs index 4d2518a7cca..562e16d05ef 100644 --- a/components/script/stylesheet_loader.rs +++ b/components/script/stylesheet_loader.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use cssparser::SourceLocation; use document_loader::LoadType; use dom::bindings::inheritance::Castable; use dom::bindings::refcounted::Trusted; @@ -22,14 +23,19 @@ use ipc_channel::router::ROUTER; use net_traits::{FetchResponseListener, FetchMetadata, FilteredMetadata, Metadata, NetworkError, ReferrerPolicy}; use net_traits::request::{CorsSettings, CredentialsMode, Destination, RequestInit, RequestMode, Type as RequestType}; use network_listener::{NetworkListener, PreInvoke}; +use parking_lot::RwLock; use servo_url::ServoUrl; use std::mem; use std::sync::Mutex; +use std::sync::atomic::AtomicBool; use style::media_queries::MediaList; -use style::shared_lock::Locked as StyleLocked; +use style::parser::ParserContext; +use style::shared_lock::{Locked, SharedRwLock}; use style::stylearc::Arc; -use style::stylesheets::{ImportRule, Stylesheet, Origin}; +use style::stylesheets::{CssRules, ImportRule, Namespaces, Stylesheet, StylesheetContents, Origin}; use style::stylesheets::StylesheetLoader as StyleStylesheetLoader; +use style::stylesheets::import_rule::ImportSheet; +use style::values::specified::url::SpecifiedUrl; pub trait StylesheetOwner { /// Returns whether this element was inserted by the parser (i.e., it should @@ -268,20 +274,43 @@ impl<'a> StylesheetLoader<'a> { } impl<'a> StyleStylesheetLoader for StylesheetLoader<'a> { + /// Request a stylesheet after parsing a given `@import` rule, and return + /// the constructed `@import` rule. fn request_stylesheet( &self, - media: Arc>, - make_import: &mut FnMut(Arc>) -> ImportRule, - make_arc: &mut FnMut(ImportRule) -> Arc>, - ) -> Arc> { - let import = make_import(media); - let url = import.url.url().expect("Invalid urls shouldn't enter the loader").clone(); + url: SpecifiedUrl, + source_location: SourceLocation, + context: &ParserContext, + lock: &SharedRwLock, + media: Arc>, + ) -> Arc> { + let sheet = Arc::new(Stylesheet { + contents: StylesheetContents { + rules: CssRules::new(Vec::new(), lock), + origin: context.stylesheet_origin, + url_data: RwLock::new(context.url_data.clone()), + dirty_on_viewport_size_change: AtomicBool::new(false), + quirks_mode: context.quirks_mode, + namespaces: RwLock::new(Namespaces::default()), + }, + media: media, + shared_lock: lock.clone(), + disabled: AtomicBool::new(false), + }); + + let stylesheet = ImportSheet(sheet.clone()); + let import = ImportRule { url, source_location, stylesheet }; + + let url = match import.url.url().cloned() { + Some(url) => url, + None => return Arc::new(lock.wrap(import)), + }; // TODO (mrnayak) : Whether we should use the original loader's CORS // setting? Fix this when spec has more details. - let source = StylesheetContextSource::Import(import.stylesheet.clone()); + let source = StylesheetContextSource::Import(sheet.clone()); self.load(source, url, None, "".to_owned()); - make_arc(import) + Arc::new(lock.wrap(import)) } } diff --git a/components/style/gecko/arc_types.rs b/components/style/gecko/arc_types.rs index 3ff90bc9584..352cd7b7e4d 100644 --- a/components/style/gecko/arc_types.rs +++ b/components/style/gecko/arc_types.rs @@ -8,14 +8,13 @@ #![allow(non_snake_case, missing_docs)] +use gecko_bindings::bindings::{RawServoImportRule, RawServoSupportsRule}; use gecko_bindings::bindings::{RawServoKeyframe, RawServoKeyframesRule}; -use gecko_bindings::bindings::{RawServoMediaList, RawServoMediaRule}; use gecko_bindings::bindings::{RawServoNamespaceRule, RawServoPageRule}; -use gecko_bindings::bindings::{RawServoRuleNode, RawServoRuleNodeStrong, RawServoDocumentRule}; -use gecko_bindings::bindings::{RawServoStyleSheet, RawServoImportRule, RawServoSupportsRule}; +use gecko_bindings::bindings::{RawServoRuleNode, RawServoRuleNodeStrong, RawServoDocumentRule, RawServoMediaRule}; use gecko_bindings::bindings::{ServoComputedValues, ServoCssRules}; -use gecko_bindings::structs::{RawServoDeclarationBlock, RawServoStyleRule}; -use gecko_bindings::structs::RawServoAnimationValue; +use gecko_bindings::structs::{RawServoAnimationValue, RawServoDeclarationBlock, RawServoStyleRule, RawServoMediaList}; +use gecko_bindings::structs::RawServoStyleSheetContents; use gecko_bindings::sugar::ownership::{HasArcFFI, HasFFI}; use media_queries::MediaList; use properties::{ComputedValues, PropertyDeclarationBlock}; @@ -23,7 +22,7 @@ use properties::animated_properties::AnimationValue; use rule_tree::StrongRuleNode; use shared_lock::Locked; use std::{mem, ptr}; -use stylesheets::{CssRules, Stylesheet, StyleRule, ImportRule, KeyframesRule, MediaRule}; +use stylesheets::{CssRules, StylesheetContents, StyleRule, ImportRule, KeyframesRule, MediaRule}; use stylesheets::{NamespaceRule, PageRule, SupportsRule, DocumentRule}; use stylesheets::keyframes_rule::Keyframe; @@ -49,8 +48,8 @@ macro_rules! impl_arc_ffi { impl_arc_ffi!(Locked => ServoCssRules [Servo_CssRules_AddRef, Servo_CssRules_Release]); -impl_arc_ffi!(Stylesheet => RawServoStyleSheet - [Servo_StyleSheet_AddRef, Servo_StyleSheet_Release]); +impl_arc_ffi!(StylesheetContents => RawServoStyleSheetContents + [Servo_StyleSheetContents_AddRef, Servo_StyleSheetContents_Release]); impl_arc_ffi!(ComputedValues => ServoComputedValues [Servo_ComputedValues_AddRef, Servo_ComputedValues_Release]); diff --git a/components/style/gecko/data.rs b/components/style/gecko/data.rs index 20f45d32671..c6a73714b26 100644 --- a/components/style/gecko/data.rs +++ b/components/style/gecko/data.rs @@ -9,18 +9,108 @@ use atomic_refcell::{AtomicRef, AtomicRefCell, AtomicRefMut}; use dom::TElement; use fnv::FnvHashMap; use gecko::rules::{CounterStyleRule, FontFaceRule}; -use gecko_bindings::bindings::RawServoStyleSet; +use gecko_bindings::bindings::{self, RawServoStyleSet}; +use gecko_bindings::structs::{ServoStyleSheet, StyleSheetInfo, ServoStyleSheetInner}; use gecko_bindings::structs::RawGeckoPresContextOwned; use gecko_bindings::structs::nsIDocument; -use gecko_bindings::sugar::ownership::{HasBoxFFI, HasFFI, HasSimpleFFI}; -use media_queries::Device; +use gecko_bindings::sugar::ownership::{HasArcFFI, HasBoxFFI, HasFFI, HasSimpleFFI}; +use invalidation::media_queries::{MediaListKey, ToMediaListKey}; +use media_queries::{Device, MediaList}; use properties::ComputedValues; use shared_lock::{Locked, StylesheetGuards, SharedRwLockReadGuard}; use stylearc::Arc; use stylesheet_set::StylesheetSet; -use stylesheets::Origin; +use stylesheets::{Origin, StylesheetContents, StylesheetInDocument}; use stylist::{ExtraStyleData, Stylist}; +/// Little wrapper to a Gecko style sheet. +#[derive(PartialEq, Eq, Debug)] +pub struct GeckoStyleSheet(*const ServoStyleSheet); + +impl ToMediaListKey for ::gecko::data::GeckoStyleSheet { + fn to_media_list_key(&self) -> MediaListKey { + use std::mem; + unsafe { + MediaListKey::from_raw(mem::transmute(self.0)) + } + } +} + +impl GeckoStyleSheet { + /// Create a `GeckoStyleSheet` from a raw `ServoStyleSheet` pointer. + #[inline] + pub unsafe fn new(s: *const ServoStyleSheet) -> Self { + debug_assert!(!s.is_null()); + bindings::Gecko_StyleSheet_AddRef(s); + Self::from_addrefed(s) + } + + /// Create a `GeckoStyleSheet` from a raw `ServoStyleSheet` pointer that + /// already holds a strong reference. + #[inline] + pub unsafe fn from_addrefed(s: *const ServoStyleSheet) -> Self { + debug_assert!(!s.is_null()); + GeckoStyleSheet(s) + } + + /// Get the raw `ServoStyleSheet` that we're wrapping. + pub fn raw(&self) -> &ServoStyleSheet { + unsafe { &*self.0 } + } + + fn inner(&self) -> &ServoStyleSheetInner { + unsafe { + &*(self.raw()._base.mInner as *const StyleSheetInfo as *const ServoStyleSheetInner) + } + } +} + +impl Drop for GeckoStyleSheet { + fn drop(&mut self) { + unsafe { bindings::Gecko_StyleSheet_Release(self.0) }; + } +} + +impl Clone for GeckoStyleSheet { + fn clone(&self) -> Self { + unsafe { bindings::Gecko_StyleSheet_AddRef(self.0) }; + GeckoStyleSheet(self.0) + } +} + +impl StylesheetInDocument for GeckoStyleSheet { + fn contents(&self, _: &SharedRwLockReadGuard) -> &StylesheetContents { + debug_assert!(!self.inner().mContents.mRawPtr.is_null()); + unsafe { + let contents = + (&**StylesheetContents::as_arc(&&*self.inner().mContents.mRawPtr)) as *const _; + &*contents + } + } + + fn media<'a>(&'a self, guard: &'a SharedRwLockReadGuard) -> Option<&'a MediaList> { + use gecko_bindings::structs::ServoMediaList; + use std::mem; + + unsafe { + let servo_media_list = + self.raw()._base.mMedia.mRawPtr as *const ServoMediaList; + if servo_media_list.is_null() { + return None; + } + let raw_list = &*(*servo_media_list).mRawList.mRawPtr; + let list = Locked::::as_arc(mem::transmute(&raw_list)); + Some(list.read_with(guard)) + } + } + + // All the stylesheets Servo knows about are enabled, because that state is + // handled externally by Gecko. + fn enabled(&self) -> bool { + true + } +} + /// The container for data that a Servo-backed Gecko document needs to style /// itself. pub struct PerDocumentStyleDataImpl { @@ -28,7 +118,7 @@ pub struct PerDocumentStyleDataImpl { pub stylist: Stylist, /// List of stylesheets, mirrored from Gecko. - pub stylesheets: StylesheetSet, + pub stylesheets: StylesheetSet, /// List of effective font face rules. pub font_faces: Vec<(Arc>, Origin)>, @@ -87,12 +177,14 @@ impl PerDocumentStyleDataImpl { let author_style_disabled = self.stylesheets.author_style_disabled(); self.stylist.clear(); let iter = self.stylesheets.flush(document_element); - self.stylist.rebuild(iter, - &StylesheetGuards::same(guard), - /* ua_sheets = */ None, - /* stylesheets_changed = */ true, - author_style_disabled, - &mut extra_data); + self.stylist.rebuild( + iter, + &StylesheetGuards::same(guard), + /* ua_sheets = */ None, + /* stylesheets_changed = */ true, + author_style_disabled, + &mut extra_data + ); } /// Get the default computed values for this document. diff --git a/components/style/gecko/generated/atom_macro.rs b/components/style/gecko/generated/atom_macro.rs index 8bd108847d2..e07376ccc74 100644 --- a/components/style/gecko/generated/atom_macro.rs +++ b/components/style/gecko/generated/atom_macro.rs @@ -4334,6 +4334,8 @@ cfg_if! { pub static nsGkAtoms_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms18overlay_scrollbarsE"] pub static nsGkAtoms_overlay_scrollbars: *mut nsIAtom; + #[link_name = "_ZN9nsGkAtoms28windows_accent_color_appliesE"] + pub static nsGkAtoms_windows_accent_color_applies: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms21windows_default_themeE"] pub static nsGkAtoms_windows_default_theme: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms18mac_graphite_themeE"] @@ -4384,6 +4386,8 @@ cfg_if! { pub static nsGkAtoms__moz_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms23_moz_overlay_scrollbarsE"] pub static nsGkAtoms__moz_overlay_scrollbars: *mut nsIAtom; + #[link_name = "_ZN9nsGkAtoms33_moz_windows_accent_color_appliesE"] + pub static nsGkAtoms__moz_windows_accent_color_applies: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms26_moz_windows_default_themeE"] pub static nsGkAtoms__moz_windows_default_theme: *mut nsIAtom; #[link_name = "_ZN9nsGkAtoms23_moz_mac_graphite_themeE"] @@ -9455,6 +9459,8 @@ cfg_if! { pub static nsGkAtoms_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "?overlay_scrollbars@nsGkAtoms@@2PEAVnsIAtom@@EA"] pub static nsGkAtoms_overlay_scrollbars: *mut nsIAtom; + #[link_name = "?windows_accent_color_applies@nsGkAtoms@@2PEAVnsIAtom@@EA"] + pub static nsGkAtoms_windows_accent_color_applies: *mut nsIAtom; #[link_name = "?windows_default_theme@nsGkAtoms@@2PEAVnsIAtom@@EA"] pub static nsGkAtoms_windows_default_theme: *mut nsIAtom; #[link_name = "?mac_graphite_theme@nsGkAtoms@@2PEAVnsIAtom@@EA"] @@ -9505,6 +9511,8 @@ cfg_if! { pub static nsGkAtoms__moz_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "?_moz_overlay_scrollbars@nsGkAtoms@@2PEAVnsIAtom@@EA"] pub static nsGkAtoms__moz_overlay_scrollbars: *mut nsIAtom; + #[link_name = "?_moz_windows_accent_color_applies@nsGkAtoms@@2PEAVnsIAtom@@EA"] + pub static nsGkAtoms__moz_windows_accent_color_applies: *mut nsIAtom; #[link_name = "?_moz_windows_default_theme@nsGkAtoms@@2PEAVnsIAtom@@EA"] pub static nsGkAtoms__moz_windows_default_theme: *mut nsIAtom; #[link_name = "?_moz_mac_graphite_theme@nsGkAtoms@@2PEAVnsIAtom@@EA"] @@ -14576,6 +14584,8 @@ cfg_if! { pub static nsGkAtoms_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "\x01?overlay_scrollbars@nsGkAtoms@@2PAVnsIAtom@@A"] pub static nsGkAtoms_overlay_scrollbars: *mut nsIAtom; + #[link_name = "\x01?windows_accent_color_applies@nsGkAtoms@@2PAVnsIAtom@@A"] + pub static nsGkAtoms_windows_accent_color_applies: *mut nsIAtom; #[link_name = "\x01?windows_default_theme@nsGkAtoms@@2PAVnsIAtom@@A"] pub static nsGkAtoms_windows_default_theme: *mut nsIAtom; #[link_name = "\x01?mac_graphite_theme@nsGkAtoms@@2PAVnsIAtom@@A"] @@ -14626,6 +14636,8 @@ cfg_if! { pub static nsGkAtoms__moz_scrollbar_thumb_proportional: *mut nsIAtom; #[link_name = "\x01?_moz_overlay_scrollbars@nsGkAtoms@@2PAVnsIAtom@@A"] pub static nsGkAtoms__moz_overlay_scrollbars: *mut nsIAtom; + #[link_name = "\x01?_moz_windows_accent_color_applies@nsGkAtoms@@2PAVnsIAtom@@A"] + pub static nsGkAtoms__moz_windows_accent_color_applies: *mut nsIAtom; #[link_name = "\x01?_moz_windows_default_theme@nsGkAtoms@@2PAVnsIAtom@@A"] pub static nsGkAtoms__moz_windows_default_theme: *mut nsIAtom; #[link_name = "\x01?_moz_mac_graphite_theme@nsGkAtoms@@2PAVnsIAtom@@A"] @@ -19700,6 +19712,8 @@ macro_rules! atom { { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms_scrollbar_thumb_proportional as *mut _) } }; ("overlay-scrollbars") => { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms_overlay_scrollbars as *mut _) } }; +("windows-accent-color-applies") => + { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms_windows_accent_color_applies as *mut _) } }; ("windows-default-theme") => { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms_windows_default_theme as *mut _) } }; ("mac-graphite-theme") => @@ -19750,6 +19764,8 @@ macro_rules! atom { { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms__moz_scrollbar_thumb_proportional as *mut _) } }; ("-moz-overlay-scrollbars") => { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms__moz_overlay_scrollbars as *mut _) } }; +("-moz-windows-accent-color-applies") => + { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms__moz_windows_accent_color_applies as *mut _) } }; ("-moz-windows-default-theme") => { unsafe { $crate::string_cache::atom_macro::atom_from_static($crate::string_cache::atom_macro::nsGkAtoms__moz_windows_default_theme as *mut _) } }; ("-moz-mac-graphite-theme") => diff --git a/components/style/gecko/generated/bindings.rs b/components/style/gecko/generated/bindings.rs index 6db35db4954..96d9b3f9dd3 100644 --- a/components/style/gecko/generated/bindings.rs +++ b/components/style/gecko/generated/bindings.rs @@ -24,6 +24,8 @@ use gecko_bindings::structs::RawGeckoFontFaceRuleList; use gecko_bindings::structs::RawGeckoNode; use gecko_bindings::structs::RawServoAnimationValue; use gecko_bindings::structs::RawGeckoServoAnimationValueList; +use gecko_bindings::structs::RawServoMediaList; +use gecko_bindings::structs::RawServoStyleSheetContents; use gecko_bindings::structs::RawServoDeclarationBlock; use gecko_bindings::structs::RawServoStyleRule; use gecko_bindings::structs::RawGeckoPresContext; @@ -305,11 +307,9 @@ pub type ServoCssRulesBorrowed<'a> = &'a ServoCssRules; pub type ServoCssRulesBorrowedOrNull<'a> = Option<&'a ServoCssRules>; enum ServoCssRulesVoid { } pub struct ServoCssRules(ServoCssRulesVoid); -pub type RawServoStyleSheetStrong = ::gecko_bindings::sugar::ownership::Strong; -pub type RawServoStyleSheetBorrowed<'a> = &'a RawServoStyleSheet; -pub type RawServoStyleSheetBorrowedOrNull<'a> = Option<&'a RawServoStyleSheet>; -enum RawServoStyleSheetVoid { } -pub struct RawServoStyleSheet(RawServoStyleSheetVoid); +pub type RawServoStyleSheetContentsStrong = ::gecko_bindings::sugar::ownership::Strong; +pub type RawServoStyleSheetContentsBorrowed<'a> = &'a RawServoStyleSheetContents; +pub type RawServoStyleSheetContentsBorrowedOrNull<'a> = Option<&'a RawServoStyleSheetContents>; pub type ServoComputedValuesStrong = ::gecko_bindings::sugar::ownership::Strong; pub type ServoComputedValuesBorrowed<'a> = &'a ServoComputedValues; pub type ServoComputedValuesBorrowedOrNull<'a> = Option<&'a ServoComputedValues>; @@ -342,8 +342,6 @@ pub struct RawServoKeyframesRule(RawServoKeyframesRuleVoid); pub type RawServoMediaListStrong = ::gecko_bindings::sugar::ownership::Strong; pub type RawServoMediaListBorrowed<'a> = &'a RawServoMediaList; pub type RawServoMediaListBorrowedOrNull<'a> = Option<&'a RawServoMediaList>; -enum RawServoMediaListVoid { } -pub struct RawServoMediaList(RawServoMediaListVoid); pub type RawServoMediaRuleStrong = ::gecko_bindings::sugar::ownership::Strong; pub type RawServoMediaRuleBorrowed<'a> = &'a RawServoMediaRule; pub type RawServoMediaRuleBorrowedOrNull<'a> = Option<&'a RawServoMediaRule>; @@ -390,10 +388,12 @@ extern "C" { pub fn Servo_CssRules_Release(ptr: ServoCssRulesBorrowed); } extern "C" { - pub fn Servo_StyleSheet_AddRef(ptr: RawServoStyleSheetBorrowed); + pub fn Servo_StyleSheetContents_AddRef(ptr: + RawServoStyleSheetContentsBorrowed); } extern "C" { - pub fn Servo_StyleSheet_Release(ptr: RawServoStyleSheetBorrowed); + pub fn Servo_StyleSheetContents_Release(ptr: + RawServoStyleSheetContentsBorrowed); } extern "C" { pub fn Servo_ComputedValues_AddRef(ptr: ServoComputedValuesBorrowed); @@ -544,10 +544,10 @@ extern "C" { parent: *mut ServoStyleSheet, reusable_sheets: *mut LoaderReusableStyleSheets, - child_sheet: RawServoStyleSheetBorrowed, base_url_data: *mut RawGeckoURLExtraData, url_bytes: *const u8, url_length: u32, - media_list: RawServoMediaListStrong); + media_list: RawServoMediaListStrong) + -> *mut ServoStyleSheet; } extern "C" { pub fn Gecko_ElementState(element: RawGeckoElementBorrowed) -> u64; @@ -1416,6 +1416,17 @@ extern "C" { RawGeckoPresContextBorrowed) -> i32; } +extern "C" { + pub fn Gecko_StyleSheet_Clone(aSheet: *const ServoStyleSheet, + aNewParentSheet: *const ServoStyleSheet) + -> *mut ServoStyleSheet; +} +extern "C" { + pub fn Gecko_StyleSheet_AddRef(aSheet: *const ServoStyleSheet); +} +extern "C" { + pub fn Gecko_StyleSheet_Release(aSheet: *const ServoStyleSheet); +} extern "C" { pub fn Gecko_GetMediaFeatures() -> *const nsMediaFeature; } @@ -1813,53 +1824,41 @@ extern "C" { extern "C" { pub fn Servo_Element_ClearData(node: RawGeckoElementBorrowed); } -extern "C" { - pub fn Servo_StyleSheet_Empty(parsing_mode: SheetParsingMode) - -> RawServoStyleSheetStrong; -} extern "C" { pub fn Servo_StyleSheet_FromUTF8Bytes(loader: *mut Loader, gecko_stylesheet: *mut ServoStyleSheet, data: *const nsACString, parsing_mode: SheetParsingMode, - media_list: - *const RawServoMediaList, extra_data: *mut RawGeckoURLExtraData, line_number_offset: u32, quirks_mode: nsCompatibility) - -> RawServoStyleSheetStrong; + -> RawServoStyleSheetContentsStrong; } extern "C" { - pub fn Servo_StyleSheet_ClearAndUpdate(stylesheet: - RawServoStyleSheetBorrowed, - loader: *mut Loader, - gecko_stylesheet: - *mut ServoStyleSheet, - data: *const nsACString, - extra_data: - *mut RawGeckoURLExtraData, - line_number_offset: u32, - reusable_sheets: - *mut LoaderReusableStyleSheets); + pub fn Servo_StyleSheet_Empty(parsing_mode: SheetParsingMode) + -> RawServoStyleSheetContentsStrong; } extern "C" { - pub fn Servo_StyleSheet_HasRules(sheet: RawServoStyleSheetBorrowed) + pub fn Servo_StyleSheet_HasRules(sheet: + RawServoStyleSheetContentsBorrowed) -> bool; } extern "C" { - pub fn Servo_StyleSheet_GetRules(sheet: RawServoStyleSheetBorrowed) + pub fn Servo_StyleSheet_GetRules(sheet: + RawServoStyleSheetContentsBorrowed) -> ServoCssRulesStrong; } extern "C" { - pub fn Servo_StyleSheet_Clone(sheet: RawServoStyleSheetBorrowed) - -> RawServoStyleSheetStrong; + pub fn Servo_StyleSheet_Clone(sheet: RawServoStyleSheetContentsBorrowed, + reference_sheet: *const ServoStyleSheet) + -> RawServoStyleSheetContentsStrong; } extern "C" { pub fn Servo_StyleSheet_SizeOfIncludingThis(malloc_size_of: MallocSizeOf, sheet: - RawServoStyleSheetBorrowed) + RawServoStyleSheetContentsBorrowed) -> usize; } extern "C" { @@ -1882,30 +1881,26 @@ extern "C" { } extern "C" { pub fn Servo_StyleSet_AppendStyleSheet(set: RawServoStyleSetBorrowed, - sheet: RawServoStyleSheetBorrowed, - unique_id: u64); + gecko_sheet: + *const ServoStyleSheet); } extern "C" { pub fn Servo_StyleSet_PrependStyleSheet(set: RawServoStyleSetBorrowed, - sheet: RawServoStyleSheetBorrowed, - unique_id: u64); + gecko_sheet: + *const ServoStyleSheet); } extern "C" { pub fn Servo_StyleSet_RemoveStyleSheet(set: RawServoStyleSetBorrowed, - unique_id: u64); + gecko_sheet: + *const ServoStyleSheet); } extern "C" { pub fn Servo_StyleSet_InsertStyleSheetBefore(set: RawServoStyleSetBorrowed, - sheet: - RawServoStyleSheetBorrowed, - unique_id: u64, - before_unique_id: u64); -} -extern "C" { - pub fn Servo_StyleSet_UpdateStyleSheet(set: RawServoStyleSetBorrowed, - sheet: RawServoStyleSheetBorrowed, - unique_id: u64); + gecko_sheet: + *const ServoStyleSheet, + before: + *const ServoStyleSheet); } extern "C" { pub fn Servo_StyleSet_FlushStyleSheets(set: RawServoStyleSetBorrowed, @@ -1967,7 +1962,8 @@ extern "C" { } extern "C" { pub fn Servo_CssRules_InsertRule(rules: ServoCssRulesBorrowed, - sheet: RawServoStyleSheetBorrowed, + sheet: + RawServoStyleSheetContentsBorrowed, rule: *const nsACString, index: u32, nested: bool, loader: *mut Loader, gecko_stylesheet: *mut ServoStyleSheet, @@ -2154,7 +2150,7 @@ extern "C" { } extern "C" { pub fn Servo_ImportRule_GetSheet(rule: RawServoImportRuleBorrowed) - -> *const RawServoStyleSheet; + -> *const ServoStyleSheet; } extern "C" { pub fn Servo_Keyframe_GetKeyText(keyframe: RawServoKeyframeBorrowed, @@ -2197,7 +2193,8 @@ extern "C" { } extern "C" { pub fn Servo_KeyframesRule_AppendRule(rule: RawServoKeyframesRuleBorrowed, - sheet: RawServoStyleSheetBorrowed, + sheet: + RawServoStyleSheetContentsBorrowed, css: *const nsACString) -> bool; } extern "C" { @@ -2264,6 +2261,11 @@ extern "C" { nsCSSPropertyID) -> RawServoAnimationValueStrong; } +extern "C" { + pub fn Servo_ComputedValues_SpecifiesAnimationsOrTransitions(computed_values: + ServoComputedValuesBorrowed) + -> bool; +} extern "C" { pub fn Servo_Property_IsAnimatable(property: nsCSSPropertyID) -> bool; } @@ -2679,6 +2681,10 @@ extern "C" { set: RawServoStyleSetBorrowed) -> ServoComputedValuesStrong; } +extern "C" { + pub fn Servo_SetExplicitStyle(element: RawGeckoElementBorrowed, + primary_style: ServoComputedValuesBorrowed); +} extern "C" { pub fn Servo_HasAuthorSpecifiedRules(element: RawGeckoElementBorrowed, rule_type_mask: u32, diff --git a/components/style/gecko/generated/structs_debug.rs b/components/style/gecko/generated/structs_debug.rs index 0fcebe94d17..57c12b17030 100644 --- a/components/style/gecko/generated/structs_debug.rs +++ b/components/style/gecko/generated/structs_debug.rs @@ -1033,6 +1033,16 @@ pub mod root { use self::super::super::root; #[repr(C)] #[derive(Debug, Copy, Clone)] + pub struct __is_swappable { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct __is_nothrow_swappable { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct pair<_T1, _T2> { pub first: _T1, pub second: _T2, @@ -1041,6 +1051,8 @@ pub mod root { } pub type pair_first_type<_T1> = _T1; pub type pair_second_type<_T2> = _T2; + pub type pair__PCCP = u8; + pub type pair__PCCFP = u8; #[repr(C)] #[derive(Debug, Copy)] pub struct input_iterator_tag { @@ -1070,10 +1082,17 @@ pub mod root { pub type iterator_pointer<_Pointer> = _Pointer; pub type iterator_reference<_Reference> = _Reference; #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct __iterator_traits { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct iterator_traits { pub _address: u8, } #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct reverse_iterator<_Iterator> { pub current: _Iterator, pub _phantom_0: ::std::marker::PhantomData<::std::cell::UnsafeCell<_Iterator>>, @@ -1143,8 +1162,9 @@ pub mod root { root::nsSubstringTuple; pub type nsStringRepr_string_type = ::nsstring::nsStringRepr; pub type nsStringRepr_const_iterator = - root::nsReadingIterator; - pub type nsStringRepr_iterator = root::nsWritingIterator; + root::nsReadingIterator; + pub type nsStringRepr_iterator = + root::nsWritingIterator; pub type nsStringRepr_comparator_type = root::nsStringComparator; pub type nsStringRepr_char_iterator = *mut root::mozilla::detail::nsStringRepr_char_type; @@ -1234,9 +1254,9 @@ pub mod root { root::nsCSubstringTuple; pub type nsCStringRepr_string_type = root::nsCString; pub type nsCStringRepr_const_iterator = - root::nsReadingIterator<::std::os::raw::c_char>; + root::nsReadingIterator; pub type nsCStringRepr_iterator = - root::nsWritingIterator<::std::os::raw::c_char>; + root::nsWritingIterator; pub type nsCStringRepr_comparator_type = root::nsCStringComparator; pub type nsCStringRepr_char_iterator = @@ -10314,6 +10334,8 @@ pub mod root { PropertyStyleAnimationValuePair ) , "::" , stringify ! ( mValue ) )); } + pub type ComputedKeyframeValues = + root::nsTArray; #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_3() { assert_eq!(::std::mem::size_of::() , @@ -10570,6 +10592,36 @@ pub mod root { _unused: [u8; 0], } #[repr(C)] + pub struct ServoStyleSheetInner { + pub _base: root::mozilla::StyleSheetInfo, + pub mContents: root::RefPtr, + pub mURLData: root::RefPtr, + } + #[test] + fn bindgen_test_layout_ServoStyleSheetInner() { + assert_eq!(::std::mem::size_of::() , + 216usize , concat ! ( + "Size of: " , stringify ! ( ServoStyleSheetInner ) )); + assert_eq! (::std::mem::align_of::() , + 8usize , concat ! ( + "Alignment of " , stringify ! ( ServoStyleSheetInner ) + )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoStyleSheetInner ) ) . + mContents as * const _ as usize } , 200usize , concat + ! ( + "Alignment of field: " , stringify ! ( + ServoStyleSheetInner ) , "::" , stringify ! ( + mContents ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoStyleSheetInner ) ) . + mURLData as * const _ as usize } , 208usize , concat ! + ( + "Alignment of field: " , stringify ! ( + ServoStyleSheetInner ) , "::" , stringify ! ( mURLData + ) )); + } + #[repr(C)] #[derive(Debug)] pub struct URIPrincipalReferrerPolicyAndCORSModeHashKey { pub _base: root::nsURIHashKey, @@ -11426,6 +11478,26 @@ pub mod root { } #[repr(C)] #[derive(Debug)] + pub struct ServoMediaList { + pub _base: root::mozilla::dom::MediaList, + pub mRawList: root::RefPtr, + } + #[test] + fn bindgen_test_layout_ServoMediaList() { + assert_eq!(::std::mem::size_of::() , 64usize , + concat ! ( "Size of: " , stringify ! ( ServoMediaList ) + )); + assert_eq! (::std::mem::align_of::() , 8usize , + concat ! ( + "Alignment of " , stringify ! ( ServoMediaList ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoMediaList ) ) . mRawList as + * const _ as usize } , 56usize , concat ! ( + "Alignment of field: " , stringify ! ( ServoMediaList + ) , "::" , stringify ! ( mRawList ) )); + } + #[repr(C)] + #[derive(Debug)] pub struct CSSFontFaceDescriptors { pub mFamily: root::nsCSSValue, pub mStyle: root::nsCSSValue, @@ -14402,6 +14474,11 @@ pub mod root { AutoSetAsyncStackForNewCalls ) , "::" , stringify ! ( oldAsyncCallIsExplicit ) )); } + pub type WarningReporter = + ::std::option::Option; #[repr(C)] #[derive(Debug)] pub struct AutoHideScriptedCaller { @@ -14563,6 +14640,141 @@ pub mod root { pub struct JSCompartment { _unused: [u8; 0], } + /** + * Describes a single error or warning that occurs in the execution of script. + */ + #[repr(C)] + pub struct JSErrorReport { + pub _base: root::JSErrorBase, + pub linebuf_: *const u16, + pub linebufLength_: usize, + pub tokenOffset_: usize, + pub notes: root::mozilla::UniquePtr, + pub flags: ::std::os::raw::c_uint, + pub exnType: i16, + pub _bitfield_1: u8, + pub __bindgen_padding_0: u8, + } + #[test] + fn bindgen_test_layout_JSErrorReport() { + assert_eq!(::std::mem::size_of::() , 72usize , concat ! + ( "Size of: " , stringify ! ( JSErrorReport ) )); + assert_eq! (::std::mem::align_of::() , 8usize , concat + ! ( "Alignment of " , stringify ! ( JSErrorReport ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . linebuf_ as * + const _ as usize } , 32usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( linebuf_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . linebufLength_ as + * const _ as usize } , 40usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( linebufLength_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . tokenOffset_ as * + const _ as usize } , 48usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( tokenOffset_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . notes as * const + _ as usize } , 56usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( notes ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . flags as * const + _ as usize } , 64usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( flags ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . exnType as * + const _ as usize } , 68usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( exnType ) )); + } + impl JSErrorReport { + #[inline] + pub fn isMuted(&self) -> bool { + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + let mask = 1u64 as u8; + let val = (unit_field_val & mask) >> 0usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_isMuted(&mut self, val: bool) { + let mask = 1u64 as u8; + let val = val as u8 as u8; + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + unit_field_val &= !mask; + unit_field_val |= (val << 0usize) & mask; + unsafe { + ::std::ptr::copy_nonoverlapping(&unit_field_val as *const _ as + *const u8, + &mut self._bitfield_1 as + *mut _ as *mut u8, + ::std::mem::size_of::()); + } + } + #[inline] + pub fn ownsLinebuf_(&self) -> bool { + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + let mask = 2u64 as u8; + let val = (unit_field_val & mask) >> 1usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_ownsLinebuf_(&mut self, val: bool) { + let mask = 2u64 as u8; + let val = val as u8 as u8; + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + unit_field_val &= !mask; + unit_field_val |= (val << 1usize) & mask; + unsafe { + ::std::ptr::copy_nonoverlapping(&unit_field_val as *const _ as + *const u8, + &mut self._bitfield_1 as + *mut _ as *mut u8, + ::std::mem::size_of::()); + } + } + #[inline] + pub fn new_bitfield_1(isMuted: bool, ownsLinebuf_: bool) -> u8 { + ({ ({ 0 } | ((isMuted as u8 as u8) << 0usize) & (1u64 as u8)) } | + ((ownsLinebuf_ as u8 as u8) << 1usize) & (2u64 as u8)) + } + } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct JSRuntime { @@ -15467,7 +15679,7 @@ pub mod root { #[derive(Debug)] pub struct gfxFontFeatureValueSet_ValueList { pub name: ::nsstring::nsStringRepr, - pub featureSelectors: root::nsTArray<::std::os::raw::c_uint>, + pub featureSelectors: root::nsTArray, } #[test] fn bindgen_test_layout_gfxFontFeatureValueSet_ValueList() { @@ -15572,7 +15784,7 @@ pub mod root { pub struct gfxFontFeatureValueSet_FeatureValueHashEntry { pub _base: root::PLDHashEntryHdr, pub mKey: root::gfxFontFeatureValueSet_FeatureValueHashKey, - pub mValues: root::nsTArray<::std::os::raw::c_uint>, + pub mValues: root::nsTArray, } pub type gfxFontFeatureValueSet_FeatureValueHashEntry_KeyType = *const root::gfxFontFeatureValueSet_FeatureValueHashKey; @@ -15682,7 +15894,7 @@ pub mod root { pub alternateValues: root::nsTArray, pub featureValueLookup: root::RefPtr, pub fontFeatureSettings: root::nsTArray, - pub fontVariationSettings: root::nsTArray, + pub fontVariationSettings: root::nsTArray, pub languageOverride: u32, } #[test] @@ -19509,7 +19721,7 @@ pub mod root { pub mUpgradeInsecurePreloads: bool, pub mHSTSPrimingURIList: [u64; 6usize], pub mDocumentContainer: u64, - pub mCharacterSet: root::mozilla::NotNull<*const root::mozilla::Encoding>, + pub mCharacterSet: root::mozilla::NotNull<*const root::nsIDocument_Encoding>, pub mCharacterSetSource: i32, pub mParentDocument: *mut root::nsIDocument, pub mCachedRootElement: *mut root::mozilla::dom::Element, @@ -19567,7 +19779,7 @@ pub mod root { */ pub mFrameRequestCallbackCounter: i32, pub mStaticCloneCount: u32, - pub mBlockedTrackingNodes: root::nsTArray>, + pub mBlockedTrackingNodes: root::nsTArray, pub mWindow: *mut root::nsPIDOMWindowInner, pub mCachedEncoder: root::nsCOMPtr, pub mFrameRequestCallbacks: root::nsTArray, @@ -22347,6 +22559,11 @@ pub mod root { } } #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct nsBindingManager { + _unused: [u8; 0], + } + #[repr(C)] #[derive(Debug)] pub struct nsCSSCounterStyleRule { pub _base: root::mozilla::css::Rule, @@ -25824,11 +26041,6 @@ pub mod root { "Alignment of field: " , stringify ! ( nsNodeInfoManager ) , "::" , stringify ! ( mRecentlyUsedNodeInfos ) )); } - #[repr(C)] - #[derive(Debug, Copy, Clone)] - pub struct nsBindingManager { - _unused: [u8; 0], - } pub type NSPropertyFunc = ::std::option::Option, + pub mContent: root::nsCOMPtr, /** * Cache of Attrs. */ @@ -26294,57 +26506,57 @@ pub mod root { pub struct nsDOMMutationObserver { _unused: [u8; 0], } - pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_LISTENERMANAGER; - pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_PROPERTIES; - pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_ANONYMOUS_ROOT; - pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; - pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_NATIVE_ANONYMOUS_ROOT; - pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_FORCE_XBL_BINDINGS; - pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_MAY_BE_IN_BINDING_MNGR; - pub const NODE_IS_EDITABLE: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_EDITABLE; - pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_NATIVE_ANONYMOUS; - pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_IN_SHADOW_TREE; - pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_EMPTY_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_SLOW_SELECTOR; - pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_EDGE_CHILD_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; - pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_ALL_SELECTOR_FLAGS; - pub const NODE_NEEDS_FRAME: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_NEEDS_FRAME; - pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_DESCENDANTS_NEED_FRAMES; - pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_ACCESSKEY; - pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_DIRECTION_RTL; - pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_HAS_DIRECTION_LTR; - pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_ALL_DIRECTION_FLAGS; - pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_CHROME_ONLY_ACCESS; - pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; - pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_85 = - _bindgen_ty_85::NODE_TYPE_SPECIFIC_BITS_OFFSET; + pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_LISTENERMANAGER; + pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_PROPERTIES; + pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_ANONYMOUS_ROOT; + pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; + pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_NATIVE_ANONYMOUS_ROOT; + pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_FORCE_XBL_BINDINGS; + pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_MAY_BE_IN_BINDING_MNGR; + pub const NODE_IS_EDITABLE: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_EDITABLE; + pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_NATIVE_ANONYMOUS; + pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_IN_SHADOW_TREE; + pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_EMPTY_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_SLOW_SELECTOR; + pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_EDGE_CHILD_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; + pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_ALL_SELECTOR_FLAGS; + pub const NODE_NEEDS_FRAME: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_NEEDS_FRAME; + pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_DESCENDANTS_NEED_FRAMES; + pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_ACCESSKEY; + pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_DIRECTION_RTL; + pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_HAS_DIRECTION_LTR; + pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_ALL_DIRECTION_FLAGS; + pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_CHROME_ONLY_ACCESS; + pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; + pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_83 = + _bindgen_ty_83::NODE_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_85 { + pub enum _bindgen_ty_83 { NODE_HAS_LISTENERMANAGER = 4, NODE_HAS_PROPERTIES = 8, NODE_IS_ANONYMOUS_ROOT = 16, @@ -31625,7 +31837,7 @@ pub mod root { pub mRefCnt: root::nsAutoRefCnt, pub _mOwningThread: root::nsAutoOwningThread, pub mBehaviour: root::mozilla::UniquePtr, - pub mURI: root::RefPtr, + pub mURI: root::RefPtr, pub mListener: *mut root::imgINotificationObserver, pub mLoadGroup: root::nsCOMPtr, pub mLoadFlags: root::nsLoadFlags, @@ -32857,7 +33069,7 @@ pub mod root { pub _mOwningThread: root::nsAutoOwningThread, pub mLoader: *mut root::imgLoader, pub mRequest: root::nsCOMPtr, - pub mURI: root::RefPtr, + pub mURI: root::RefPtr, pub mCurrentURI: root::nsCOMPtr, pub mLoadingPrincipal: root::nsCOMPtr, pub mPrincipal: root::nsCOMPtr, @@ -32884,8 +33096,8 @@ pub mod root { pub mImageErrorCode: root::nsresult, pub mBoostCategoriesRequested: u32, pub mMutex: root::mozilla::Mutex, - pub mProgressTracker: root::RefPtr, - pub mImage: root::RefPtr, + pub mProgressTracker: root::RefPtr, + pub mImage: root::RefPtr, pub _bitfield_1: u8, pub __bindgen_padding_0: [u8; 7usize], } @@ -34472,7 +34684,7 @@ pub mod root { ) , "::" , stringify ! ( mQuotePairs ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_88() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_86() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -34483,7 +34695,7 @@ pub mod root { root::mozilla::StaticRefPtr ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_89() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_87() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -36740,7 +36952,7 @@ pub mod root { } #[repr(C)] #[derive(Debug, Copy, Clone)] - pub struct RawServoStyleSheet { + pub struct RawServoStyleSheetContents { _unused: [u8; 0], } #[repr(C)] @@ -36758,6 +36970,11 @@ pub mod root { pub struct RawServoAnimationValue { _unused: [u8; 0], } + #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct RawServoMediaList { + _unused: [u8; 0], + } pub mod nsStyleTransformMatrix { #[allow(unused_imports)] use self::super::super::root; @@ -36780,7 +36997,7 @@ pub mod root { root::nsTArray>; pub type RawGeckoKeyframeList = root::nsTArray; pub type RawGeckoComputedKeyframeValuesList = - root::nsTArray>; + root::nsTArray; pub type RawGeckoStyleAnimationList = root::nsStyleAutoArray; pub type RawGeckoFontFaceRuleList = @@ -37627,48 +37844,48 @@ pub mod root { pub struct nsAttrValueOrString { _unused: [u8; 0], } - pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; pub const ELEMENT_HAS_ANIMATION_ONLY_DIRTY_DESCENDANTS_FOR_SERVO: - root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_87 + root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_85 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_3; + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; pub const ELEMENT_IS_POTENTIAL_ANIMATION_ONLY_RESTYLE_ROOT: - root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; - pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_PENDING_RESTYLE_FLAGS; - pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; - pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_ALL_RESTYLE_FLAGS; - pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_HAS_SCROLLGRAB; - pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_87 = - _bindgen_ty_87::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; + root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; + pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_PENDING_RESTYLE_FLAGS; + pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; + pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_ALL_RESTYLE_FLAGS; + pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_HAS_SCROLLGRAB; + pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_85 = + _bindgen_ty_85::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_87 { + pub enum _bindgen_ty_85 { ELEMENT_SHARED_RESTYLE_BIT_1 = 8388608, ELEMENT_SHARED_RESTYLE_BIT_2 = 16777216, ELEMENT_SHARED_RESTYLE_BIT_3 = 33554432, @@ -38219,6 +38436,22 @@ pub mod root { } #[repr(C)] #[derive(Debug, Copy)] + pub struct _bindgen_ty_29 { + pub _address: u8, + } + impl Clone for _bindgen_ty_29 { + fn clone(&self) -> Self { *self } + } + #[repr(C)] + #[derive(Debug, Copy)] + pub struct _bindgen_ty_30 { + pub _address: u8, + } + impl Clone for _bindgen_ty_30 { + fn clone(&self) -> Self { *self } + } + #[repr(C)] + #[derive(Debug, Copy)] pub struct __va_list_tag { pub gp_offset: ::std::os::raw::c_uint, pub fp_offset: ::std::os::raw::c_uint, @@ -38257,7 +38490,7 @@ pub mod root { } pub type __builtin_va_list = [root::__va_list_tag; 1usize]; #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_90() { + fn __bindgen_test_layout_IntegralConstant_instantiation_88() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -38266,7 +38499,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_91() { + fn __bindgen_test_layout_IntegralConstant_instantiation_89() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -38275,7 +38508,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_92() { + fn __bindgen_test_layout_nsCharTraits_instantiation_90() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38286,62 +38519,33 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_93() { - assert_eq!(::std::mem::size_of::>() , - 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsReadingIterator ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator ) )); - } - #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_94() { - assert_eq!(::std::mem::size_of::>() , - 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsWritingIterator ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator ) )); - } - #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_95() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - } - #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_96() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsReadingIterator_instantiation_91() { + assert_eq!(::std::mem::size_of::>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::>() + root::nsReadingIterator + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); + root::nsReadingIterator + ) )); } #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_97() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsWritingIterator_instantiation_92() { + assert_eq!(::std::mem::size_of::>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::>() + root::nsWritingIterator + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); + root::nsWritingIterator + ) )); } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_98() { + fn __bindgen_test_layout_nsCharTraits_instantiation_93() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38352,7 +38556,33 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_99() { + fn __bindgen_test_layout_nsReadingIterator_instantiation_94() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + } + #[test] + fn __bindgen_test_layout_nsWritingIterator_instantiation_95() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + } + #[test] + fn __bindgen_test_layout_nsCharTraits_instantiation_96() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38363,7 +38593,18 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout__bindgen_ty_id_214776_instantiation_100() { + fn __bindgen_test_layout_nsCharTraits_instantiation_97() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + } + #[test] + fn __bindgen_test_layout__bindgen_ty_id_191460_instantiation_98() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -38372,7 +38613,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout__bindgen_ty_id_214812_instantiation_101() { + fn __bindgen_test_layout__bindgen_ty_id_191496_instantiation_99() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -38381,7 +38622,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_102() { + fn __bindgen_test_layout_nsTArray_instantiation_100() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38392,7 +38633,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_103() { + fn __bindgen_test_layout_Handle_instantiation_101() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38403,7 +38644,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_104() { + fn __bindgen_test_layout_Handle_instantiation_102() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38414,7 +38655,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_105() { + fn __bindgen_test_layout_Handle_instantiation_103() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38425,7 +38666,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_106() { + fn __bindgen_test_layout_MutableHandle_instantiation_104() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38436,7 +38677,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_107() { + fn __bindgen_test_layout_Rooted_instantiation_105() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38447,7 +38688,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_108() { + fn __bindgen_test_layout_DeletePolicy_instantiation_106() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38458,7 +38699,7 @@ pub mod root { root::JS::DeletePolicy ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_109() { + fn __bindgen_test_layout_nsTArray_instantiation_107() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38469,7 +38710,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_110() { + fn __bindgen_test_layout_nsTArray_instantiation_108() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38480,29 +38721,29 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_111() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_109() { + assert_eq!(::std::mem::size_of::>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::nsTArray ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_112() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_110() { + assert_eq!(::std::mem::size_of::>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::nsTArray ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_PointTyped_instantiation_113() { + fn __bindgen_test_layout_PointTyped_instantiation_111() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38513,7 +38754,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_114() { + fn __bindgen_test_layout_IntPointTyped_instantiation_112() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38524,7 +38765,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SizeTyped_instantiation_115() { + fn __bindgen_test_layout_SizeTyped_instantiation_113() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38535,7 +38776,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_116() { + fn __bindgen_test_layout_RectTyped_instantiation_114() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38546,7 +38787,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_117() { + fn __bindgen_test_layout_IntPointTyped_instantiation_115() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38557,7 +38798,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntSizeTyped_instantiation_118() { + fn __bindgen_test_layout_IntSizeTyped_instantiation_116() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38568,7 +38809,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_119() { + fn __bindgen_test_layout_IntRectTyped_instantiation_117() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38579,7 +38820,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_MarginTyped_instantiation_120() { + fn __bindgen_test_layout_MarginTyped_instantiation_118() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38590,7 +38831,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_121() { + fn __bindgen_test_layout_RectTyped_instantiation_119() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38601,7 +38842,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_122() { + fn __bindgen_test_layout_IntRectTyped_instantiation_120() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38612,7 +38853,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactor_instantiation_123() { + fn __bindgen_test_layout_ScaleFactor_instantiation_121() { assert_eq!(::std::mem::size_of::() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -38621,6 +38862,28 @@ pub mod root { u32 ) )); } #[test] + fn __bindgen_test_layout_ScaleFactors2D_instantiation_122() { + assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! + ( + "Size of template specialization: " , stringify ! ( + [u32; 2usize] ) )); + assert_eq!(::std::mem::align_of::<[u32; 2usize]>() , 4usize , concat ! + ( + "Alignment of template specialization: " , stringify ! ( + [u32; 2usize] ) )); + } + #[test] + fn __bindgen_test_layout_ScaleFactors2D_instantiation_123() { + assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! + ( + "Size of template specialization: " , stringify ! ( + [u32; 2usize] ) )); + assert_eq!(::std::mem::align_of::<[u32; 2usize]>() , 4usize , concat ! + ( + "Alignment of template specialization: " , stringify ! ( + [u32; 2usize] ) )); + } + #[test] fn __bindgen_test_layout_ScaleFactors2D_instantiation_124() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( @@ -38632,29 +38895,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_125() { - assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - [u32; 2usize] ) )); - assert_eq!(::std::mem::align_of::<[u32; 2usize]>() , 4usize , concat ! - ( - "Alignment of template specialization: " , stringify ! ( - [u32; 2usize] ) )); - } - #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_126() { - assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - [u32; 2usize] ) )); - assert_eq!(::std::mem::align_of::<[u32; 2usize]>() , 4usize , concat ! - ( - "Alignment of template specialization: " , stringify ! ( - [u32; 2usize] ) )); - } - #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_127() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_125() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38665,7 +38906,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_128() { + fn __bindgen_test_layout_already_AddRefed_instantiation_126() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38676,7 +38917,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_129() { + fn __bindgen_test_layout_already_AddRefed_instantiation_127() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38687,6 +38928,30 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_RefPtr_instantiation_128() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_129() { + assert_eq!(::std::mem::size_of::>>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray> ) + )); + assert_eq!(::std::mem::align_of::>>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray> ) + )); + } + #[test] fn __bindgen_test_layout_RefPtr_instantiation_130() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -38711,31 +38976,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_132() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_133() { - assert_eq!(::std::mem::size_of::>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray> ) - )); - assert_eq!(::std::mem::align_of::>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray> ) - )); - } - #[test] - fn __bindgen_test_layout_WeakPtr_instantiation_134() { + fn __bindgen_test_layout_WeakPtr_instantiation_132() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -38744,7 +38985,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_135() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_133() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38755,7 +38996,7 @@ pub mod root { root::nsPtrHashKey<::std::os::raw::c_void> ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_136() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_134() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38766,7 +39007,7 @@ pub mod root { root::nsPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_137() { + fn __bindgen_test_layout_nsTArray_instantiation_135() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38777,7 +39018,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_138() { + fn __bindgen_test_layout_TErrorResult_instantiation_136() { assert_eq!(::std::mem::size_of::() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38788,7 +39029,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_139() { + fn __bindgen_test_layout_TErrorResult_instantiation_137() { assert_eq!(::std::mem::size_of::() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38799,7 +39040,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_140() { + fn __bindgen_test_layout_already_AddRefed_instantiation_138() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38810,6 +39051,28 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_139() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_140() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_141() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -38821,15 +39084,15 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_142() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_142() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_143() { @@ -38843,15 +39106,15 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_144() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_RefPtr_instantiation_144() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::StyleSheet> ) )); - assert_eq!(::std::mem::align_of::>() + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + root::RefPtr ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_145() { @@ -38865,18 +39128,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_146() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_147() { + fn __bindgen_test_layout_Handle_instantiation_146() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38887,40 +39139,29 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_148() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_already_AddRefed_instantiation_147() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_148() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); } #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_149() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_150() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_151() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38931,7 +39172,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_152() { + fn __bindgen_test_layout_Handle_instantiation_150() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38942,7 +39183,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_153() { + fn __bindgen_test_layout_MutableHandle_instantiation_151() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38953,7 +39194,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_154() { + fn __bindgen_test_layout_MutableHandle_instantiation_152() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38964,6 +39205,28 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] + fn __bindgen_test_layout_DeletePolicy_instantiation_153() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_154() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] fn __bindgen_test_layout_DeletePolicy_instantiation_155() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -38976,14 +39239,14 @@ pub mod root { } #[test] fn __bindgen_test_layout_UniquePtr_instantiation_156() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); + root::mozilla::UniquePtr ) )); } #[test] fn __bindgen_test_layout_DeletePolicy_instantiation_157() { @@ -38998,14 +39261,14 @@ pub mod root { } #[test] fn __bindgen_test_layout_UniquePtr_instantiation_158() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); + root::mozilla::UniquePtr ) )); } #[test] fn __bindgen_test_layout_DeletePolicy_instantiation_159() { @@ -39052,7 +39315,18 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_163() { + fn __bindgen_test_layout_iterator_instantiation_163() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::std::iterator ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::std::iterator ) )); + } + #[test] + fn __bindgen_test_layout_DeletePolicy_instantiation_164() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39063,7 +39337,7 @@ pub mod root { root::JS::DeletePolicy ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_164() { + fn __bindgen_test_layout_UniquePtr_instantiation_165() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39074,17 +39348,6 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_iterator_instantiation_165() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::std::iterator ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::std::iterator ) )); - } - #[test] fn __bindgen_test_layout_DeletePolicy_instantiation_166() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -39107,29 +39370,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_168() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_169() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_170() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_168() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39140,7 +39381,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_171() { + fn __bindgen_test_layout_Handle_instantiation_169() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39151,7 +39392,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_172() { + fn __bindgen_test_layout_MutableHandle_instantiation_170() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39162,7 +39403,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_173() { + fn __bindgen_test_layout_nsTArray_instantiation_171() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39173,7 +39414,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_174() { + fn __bindgen_test_layout_nsTArray_instantiation_172() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39184,7 +39425,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_175() { + fn __bindgen_test_layout_Heap_instantiation_173() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39195,7 +39436,7 @@ pub mod root { root::JS::Heap ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_176() { + fn __bindgen_test_layout_Heap_instantiation_174() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39206,7 +39447,7 @@ pub mod root { root::JS::Heap<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_TenuredHeap_instantiation_177() { + fn __bindgen_test_layout_TenuredHeap_instantiation_175() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39217,7 +39458,7 @@ pub mod root { root::JS::TenuredHeap ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_178() { + fn __bindgen_test_layout_already_AddRefed_instantiation_176() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39228,20 +39469,20 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_179() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_177() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIDocument_Encoding> ) )); - assert_eq!(::std::mem::align_of::>() + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIDocument_Encoding> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_180() { + fn __bindgen_test_layout_nsTArray_instantiation_178() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39254,6 +39495,30 @@ pub mod root { ) )); } #[test] + fn __bindgen_test_layout_RefPtr_instantiation_179() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_180() { + assert_eq!(::std::mem::size_of::>>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray> ) + )); + assert_eq!(::std::mem::align_of::>>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray> ) + )); + } + #[test] fn __bindgen_test_layout_RefPtr_instantiation_181() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -39278,42 +39543,18 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_183() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_183() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray<*mut root::nsIDocument_Element> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); + root::nsTArray<*mut root::nsIDocument_Element> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_184() { - assert_eq!(::std::mem::size_of::>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray> ) - )); - assert_eq!(::std::mem::align_of::>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray> ) - )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_185() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_186() { + fn __bindgen_test_layout_RefPtr_instantiation_184() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39324,6 +39565,28 @@ pub mod root { root::RefPtr ) )); } #[test] + fn __bindgen_test_layout_nsCOMPtr_instantiation_185() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_186() { + assert_eq!(::std::mem::size_of::>>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray> ) )); + assert_eq!(::std::mem::align_of::>>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray> ) )); + } + #[test] fn __bindgen_test_layout_nsCOMPtr_instantiation_187() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -39335,29 +39598,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_188() { - assert_eq!(::std::mem::size_of::>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray> ) )); - assert_eq!(::std::mem::align_of::>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray> ) )); - } - #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_189() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_190() { + fn __bindgen_test_layout_already_AddRefed_instantiation_188() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39368,7 +39609,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_191() { + fn __bindgen_test_layout_already_AddRefed_instantiation_189() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39379,7 +39620,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_192() { + fn __bindgen_test_layout_RefPtr_instantiation_190() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39390,18 +39631,18 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_193() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_191() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray<*mut root::nsIDocument_Element> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); + root::nsTArray<*mut root::nsIDocument_Element> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_194() { + fn __bindgen_test_layout_already_AddRefed_instantiation_192() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39412,7 +39653,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_195() { + fn __bindgen_test_layout_MutableHandle_instantiation_193() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39423,29 +39664,29 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_194() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_195() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_196() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_197() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_198() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39456,7 +39697,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_199() { + fn __bindgen_test_layout_RefPtr_instantiation_197() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39467,7 +39708,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_200() { + fn __bindgen_test_layout_Handle_instantiation_198() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39478,7 +39719,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_201() { + fn __bindgen_test_layout_already_AddRefed_instantiation_199() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39489,7 +39730,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_202() { + fn __bindgen_test_layout_already_AddRefed_instantiation_200() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39500,7 +39741,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_203() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_201() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39511,18 +39752,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_204() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_205() { + fn __bindgen_test_layout_RefPtr_instantiation_202() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39533,7 +39763,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_206() { + fn __bindgen_test_layout_nsTArray_instantiation_203() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39546,7 +39776,18 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_207() { + fn __bindgen_test_layout_nsTArray_instantiation_204() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_205() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39557,7 +39798,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_208() { + fn __bindgen_test_layout_DefaultDelete_instantiation_206() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39568,7 +39809,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_209() { + fn __bindgen_test_layout_UniquePtr_instantiation_207() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39579,7 +39820,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_210() { + fn __bindgen_test_layout_already_AddRefed_instantiation_208() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39590,7 +39831,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_211() { + fn __bindgen_test_layout_nsTArray_instantiation_209() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39601,6 +39842,28 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_210() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_211() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_212() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -39612,29 +39875,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_213() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_214() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_215() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_213() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39647,7 +39888,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_216() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_214() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39658,7 +39899,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_217() { + fn __bindgen_test_layout_Handle_instantiation_215() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39669,7 +39910,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_218() { + fn __bindgen_test_layout_nsTArray_instantiation_216() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39680,7 +39921,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_219() { + fn __bindgen_test_layout_nsTArray_instantiation_217() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39691,7 +39932,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_220() { + fn __bindgen_test_layout_already_AddRefed_instantiation_218() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39702,7 +39943,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_221() { + fn __bindgen_test_layout_already_AddRefed_instantiation_219() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39713,7 +39954,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_222() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_220() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -39722,7 +39963,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_223() { + fn __bindgen_test_layout_already_AddRefed_instantiation_221() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39733,7 +39974,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_224() { + fn __bindgen_test_layout_nsTArray_instantiation_222() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39744,33 +39985,33 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_225() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_223() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_226() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_224() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_227() { + fn __bindgen_test_layout_already_AddRefed_instantiation_225() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39781,7 +40022,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_228() { + fn __bindgen_test_layout_DefaultDelete_instantiation_226() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39792,7 +40033,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_229() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_227() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39803,7 +40044,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_230() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_228() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39814,7 +40055,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_231() { + fn __bindgen_test_layout_nsTArray_instantiation_229() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39825,7 +40066,7 @@ pub mod root { root::nsTArray> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_232() { + fn __bindgen_test_layout_already_AddRefed_instantiation_230() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39836,6 +40077,28 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_231() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_232() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_233() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -39858,26 +40121,26 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_235() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_Handle_instantiation_235() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_236() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_Handle_instantiation_236() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_237() { @@ -39891,29 +40154,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_238() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_239() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_240() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_238() { assert_eq!(::std::mem::size_of::<[u64; 31usize]>() , 248usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39924,7 +40165,7 @@ pub mod root { [u64; 31usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_241() { + fn __bindgen_test_layout_already_AddRefed_instantiation_239() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39935,7 +40176,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_242() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_240() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39946,6 +40187,28 @@ pub mod root { [u64; 6usize] ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_241() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_242() { + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<::nsstring::nsStringRepr> ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<::nsstring::nsStringRepr> ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_243() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -39957,26 +40220,26 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_244() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( + fn __bindgen_test_layout_OwningNonNull_instantiation_244() { + assert_eq!(::std::mem::size_of::>() + , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( + root::mozilla::OwningNonNull ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); + root::mozilla::OwningNonNull ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_245() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_OwningNonNull_instantiation_245() { + assert_eq!(::std::mem::size_of::>() + , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::OwningNonNull ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); + root::mozilla::OwningNonNull ) )); } #[test] fn __bindgen_test_layout_OwningNonNull_instantiation_246() { @@ -39990,51 +40253,29 @@ pub mod root { root::mozilla::OwningNonNull ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_247() { - assert_eq!(::std::mem::size_of::>() - , 16usize , concat ! ( + fn __bindgen_test_layout_Handle_instantiation_247() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); + root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_248() { - assert_eq!(::std::mem::size_of::>() - , 16usize , concat ! ( + fn __bindgen_test_layout_Handle_instantiation_248() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); + root::JS::Handle ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_249() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_250() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_251() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40045,7 +40286,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_252() { + fn __bindgen_test_layout_MutableHandle_instantiation_250() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40056,6 +40297,28 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_251() { + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_252() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_253() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40079,25 +40342,25 @@ pub mod root { } #[test] fn __bindgen_test_layout_Handle_instantiation_255() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_256() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_Handle_instantiation_256() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_257() { @@ -40111,29 +40374,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_258() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_259() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_260() { + fn __bindgen_test_layout_MutableHandle_instantiation_258() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40144,7 +40385,7 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_261() { + fn __bindgen_test_layout_RefPtr_instantiation_259() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40155,7 +40396,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_262() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_260() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40166,7 +40407,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_263() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_261() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40177,7 +40418,7 @@ pub mod root { root::nsPtrHashKey<::std::os::raw::c_void> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_264() { + fn __bindgen_test_layout_already_AddRefed_instantiation_262() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40188,53 +40429,53 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_263() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_NotNull_instantiation_264() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::NotNull<*const root::nsLanguageAtomService_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::NotNull<*const root::nsLanguageAtomService_Encoding> + ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_265() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_266() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_already_AddRefed_instantiation_266() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::already_AddRefed ) )); } #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_267() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_268() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_269() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40245,7 +40486,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_270() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_268() { assert_eq!(::std::mem::size_of::<[u64; 31usize]>() , 248usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40256,7 +40497,7 @@ pub mod root { [u64; 31usize] ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_271() { + fn __bindgen_test_layout_MutableHandle_instantiation_269() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40267,7 +40508,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_272() { + fn __bindgen_test_layout_MutableHandle_instantiation_270() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40278,7 +40519,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_273() { + fn __bindgen_test_layout_already_AddRefed_instantiation_271() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40289,7 +40530,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_274() { + fn __bindgen_test_layout_DefaultDelete_instantiation_272() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40300,7 +40541,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_275() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_273() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40311,7 +40552,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_276() { + fn __bindgen_test_layout_Rooted_instantiation_274() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40322,7 +40563,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_277() { + fn __bindgen_test_layout_Rooted_instantiation_275() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40333,7 +40574,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_278() { + fn __bindgen_test_layout_already_AddRefed_instantiation_276() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40344,7 +40585,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_279() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_277() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40355,7 +40596,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_280() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_278() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40366,20 +40607,20 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_281() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_279() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIParser_Encoding> ) )); - assert_eq!(::std::mem::align_of::>() + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIParser_Encoding> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_282() { + fn __bindgen_test_layout_nsTArray_instantiation_280() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40390,7 +40631,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_283() { + fn __bindgen_test_layout_Handle_instantiation_281() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40401,6 +40642,28 @@ pub mod root { root::JS::Handle ) )); } #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_282() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_283() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] fn __bindgen_test_layout_MutableHandle_instantiation_284() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40412,29 +40675,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_285() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_286() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_287() { + fn __bindgen_test_layout_nsTArray_instantiation_285() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40445,7 +40686,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_288() { + fn __bindgen_test_layout_Handle_instantiation_286() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40456,6 +40697,28 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] + fn __bindgen_test_layout_RefPtr_instantiation_287() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr ) )); + } + #[test] + fn __bindgen_test_layout_RefPtr_instantiation_288() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr ) )); + } + #[test] fn __bindgen_test_layout_RefPtr_instantiation_289() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40467,15 +40730,17 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_290() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_290() { + assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray> + ) )); + assert_eq!(::std::mem::align_of::>>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); + root::nsTArray> + ) )); } #[test] fn __bindgen_test_layout_RefPtr_instantiation_291() { @@ -40489,31 +40754,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_292() { - assert_eq!(::std::mem::size_of::>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray> - ) )); - assert_eq!(::std::mem::align_of::>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray> - ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_293() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_294() { + fn __bindgen_test_layout_already_AddRefed_instantiation_292() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40524,7 +40765,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_295() { + fn __bindgen_test_layout_already_AddRefed_instantiation_293() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40535,7 +40776,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_296() { + fn __bindgen_test_layout_Handle_instantiation_294() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40546,7 +40787,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_297() { + fn __bindgen_test_layout_nsTArray_instantiation_295() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40557,6 +40798,32 @@ pub mod root { root::nsTArray ) )); } #[test] + fn __bindgen_test_layout_RefPtr_instantiation_296() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr + ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_297() { + assert_eq!(::std::mem::size_of::>>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray> + ) )); + assert_eq!(::std::mem::align_of::>>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray> + ) )); + } + #[test] fn __bindgen_test_layout_RefPtr_instantiation_298() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40570,33 +40837,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_299() { - assert_eq!(::std::mem::size_of::>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray> - ) )); - assert_eq!(::std::mem::align_of::>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray> - ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_300() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::RefPtr - ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::RefPtr - ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_301() { + fn __bindgen_test_layout_UniquePtr_instantiation_299() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40607,7 +40848,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_302() { + fn __bindgen_test_layout_nsTArray_instantiation_300() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40618,6 +40859,28 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_301() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_302() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_303() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40640,29 +40903,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_305() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_306() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_307() { + fn __bindgen_test_layout_already_AddRefed_instantiation_305() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40673,7 +40914,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_308() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_306() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40684,7 +40925,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_309() { + fn __bindgen_test_layout_OwningNonNull_instantiation_307() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40697,7 +40938,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_310() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_308() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40708,7 +40949,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_311() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_309() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40719,7 +40960,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_312() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_310() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40730,7 +40971,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_313() { + fn __bindgen_test_layout_DefaultDelete_instantiation_311() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40741,6 +40982,28 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_312() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_313() { + assert_eq!(::std::mem::size_of::>() + , 40usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsMainThreadPtrHolder ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsMainThreadPtrHolder ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_314() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40752,51 +41015,40 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_315() { - assert_eq!(::std::mem::size_of::>() - , 40usize , concat ! ( + fn __bindgen_test_layout_already_AddRefed_instantiation_315() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsMainThreadPtrHolder ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsMainThreadPtrHolder ) )); + root::already_AddRefed ) )); } #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_316() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::already_AddRefed ) )); } #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_317() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::already_AddRefed ) )); } #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_318() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_319() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40807,18 +41059,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_320() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_321() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_319() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40829,7 +41070,7 @@ pub mod root { root::nsPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_322() { + fn __bindgen_test_layout_already_AddRefed_instantiation_320() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40840,6 +41081,28 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_321() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_322() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_323() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -40852,28 +41115,6 @@ pub mod root { } #[test] fn __bindgen_test_layout_UniquePtr_instantiation_324() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_325() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_326() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40884,7 +41125,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_327() { + fn __bindgen_test_layout_already_AddRefed_instantiation_325() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40895,7 +41136,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_328() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_326() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -40904,7 +41145,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_329() { + fn __bindgen_test_layout_nsTArray_instantiation_327() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40915,7 +41156,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_330() { + fn __bindgen_test_layout_nsTArray_instantiation_328() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40926,7 +41167,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_331() { + fn __bindgen_test_layout_already_AddRefed_instantiation_329() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40937,7 +41178,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_332() { + fn __bindgen_test_layout_already_AddRefed_instantiation_330() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40948,7 +41189,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_333() { + fn __bindgen_test_layout_Maybe_instantiation_331() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40959,7 +41200,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_334() { + fn __bindgen_test_layout_Maybe_instantiation_332() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40970,7 +41211,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_335() { + fn __bindgen_test_layout_already_AddRefed_instantiation_333() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40981,7 +41222,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_336() { + fn __bindgen_test_layout_already_AddRefed_instantiation_334() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40992,6 +41233,28 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_335() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_336() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_337() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -41014,29 +41277,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_339() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_340() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_341() { + fn __bindgen_test_layout_already_AddRefed_instantiation_339() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41047,7 +41288,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_342() { + fn __bindgen_test_layout_Maybe_instantiation_340() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41058,7 +41299,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_343() { + fn __bindgen_test_layout_DefaultDelete_instantiation_341() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41069,7 +41310,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_344() { + fn __bindgen_test_layout_DefaultDelete_instantiation_342() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41080,7 +41321,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_pair_instantiation_345() { + fn __bindgen_test_layout_pair_instantiation_343() { assert_eq!(::std::mem::size_of::>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41091,7 +41332,7 @@ pub mod root { root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_346() { + fn __bindgen_test_layout_nsTArray_instantiation_344() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( @@ -41106,7 +41347,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_347() { + fn __bindgen_test_layout_already_AddRefed_instantiation_345() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41117,7 +41358,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_348() { + fn __bindgen_test_layout_nsTArray_instantiation_346() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41128,7 +41369,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_349() { + fn __bindgen_test_layout_nsTArray_instantiation_347() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41139,7 +41380,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_350() { + fn __bindgen_test_layout_nsTArray_instantiation_348() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41150,7 +41391,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_351() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_349() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41161,7 +41402,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_352() { + fn __bindgen_test_layout_RefPtr_instantiation_350() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41172,7 +41413,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsStyleAutoArray_instantiation_353() { + fn __bindgen_test_layout_nsStyleAutoArray_instantiation_351() { assert_eq!(::std::mem::size_of::>() , 64usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41183,6 +41424,28 @@ pub mod root { root::nsStyleAutoArray ) )); } #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_352() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_353() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_354() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -41195,28 +41458,6 @@ pub mod root { } #[test] fn __bindgen_test_layout_UniquePtr_instantiation_355() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_356() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_357() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41227,7 +41468,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_358() { + fn __bindgen_test_layout_RefPtr_instantiation_356() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41238,7 +41479,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_359() { + fn __bindgen_test_layout_RefPtr_instantiation_357() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41249,7 +41490,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_NonNull_instantiation_360() { + fn __bindgen_test_layout_NonNull_instantiation_358() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41262,7 +41503,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_NonNull_instantiation_361() { + fn __bindgen_test_layout_NonNull_instantiation_359() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41275,7 +41516,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_362() { + fn __bindgen_test_layout_Handle_instantiation_360() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41286,7 +41527,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_363() { + fn __bindgen_test_layout_MutableHandle_instantiation_361() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41297,7 +41538,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_364() { + fn __bindgen_test_layout_Maybe_instantiation_362() { assert_eq!(::std::mem::size_of::<[u64; 18usize]>() , 144usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41308,7 +41549,7 @@ pub mod root { [u64; 18usize] ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_365() { + fn __bindgen_test_layout_Maybe_instantiation_363() { assert_eq!(::std::mem::size_of::<[u64; 18usize]>() , 144usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41319,7 +41560,7 @@ pub mod root { [u64; 18usize] ) )); } #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_366() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_364() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41330,7 +41571,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_367() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_365() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41341,7 +41582,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_368() { + fn __bindgen_test_layout_already_AddRefed_instantiation_366() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41352,7 +41593,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_369() { + fn __bindgen_test_layout_already_AddRefed_instantiation_367() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41363,7 +41604,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_370() { + fn __bindgen_test_layout_nsTArray_instantiation_368() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41374,7 +41615,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_371() { + fn __bindgen_test_layout_nsTArray_instantiation_369() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41385,7 +41626,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_372() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_370() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41396,7 +41637,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_373() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_371() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41409,7 +41650,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_374() { + fn __bindgen_test_layout_already_AddRefed_instantiation_372() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41420,7 +41661,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_375() { + fn __bindgen_test_layout_nsTArray_instantiation_373() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41433,7 +41674,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_376() { + fn __bindgen_test_layout_Handle_instantiation_374() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41444,7 +41685,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_377() { + fn __bindgen_test_layout_Handle_instantiation_375() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41455,7 +41696,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_378() { + fn __bindgen_test_layout_RefPtr_instantiation_376() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41466,7 +41707,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_379() { + fn __bindgen_test_layout_Handle_instantiation_377() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41477,7 +41718,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_380() { + fn __bindgen_test_layout_MutableHandle_instantiation_378() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41488,6 +41729,26 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] + fn __bindgen_test_layout_Sequence_instantiation_379() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( u64 ) + )); + assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + u64 ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_380() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] fn __bindgen_test_layout_Sequence_instantiation_381() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) @@ -41497,7 +41758,16 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_382() { + fn __bindgen_test_layout_Sequence_instantiation_382() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( u64 ) + )); + assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + u64 ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_383() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41508,36 +41778,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_Sequence_instantiation_383() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( u64 ) - )); - assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - u64 ) )); - } - #[test] - fn __bindgen_test_layout_Sequence_instantiation_384() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( u64 ) - )); - assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - u64 ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_385() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_386() { + fn __bindgen_test_layout_Handle_instantiation_384() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41548,6 +41789,28 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_385() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_386() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] fn __bindgen_test_layout_MutableHandle_instantiation_387() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -41560,28 +41823,6 @@ pub mod root { } #[test] fn __bindgen_test_layout_Handle_instantiation_388() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_389() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_390() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41592,7 +41833,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_391() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_389() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41603,7 +41844,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsClassHashtable_instantiation_392() { + fn __bindgen_test_layout_nsClassHashtable_instantiation_390() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41614,7 +41855,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_393() { + fn __bindgen_test_layout_Handle_instantiation_391() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41625,29 +41866,29 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] + fn __bindgen_test_layout_nsTArray_instantiation_392() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_393() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + } + #[test] fn __bindgen_test_layout_nsTArray_instantiation_394() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_395() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_396() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41658,7 +41899,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_397() { + fn __bindgen_test_layout_already_AddRefed_instantiation_395() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41669,7 +41910,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_398() { + fn __bindgen_test_layout_Handle_instantiation_396() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41680,7 +41921,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_399() { + fn __bindgen_test_layout_nsTArray_instantiation_397() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41691,7 +41932,7 @@ pub mod root { root::nsTArray<*mut root::mozilla::css::DocumentRule> ) )); } #[test] - fn __bindgen_test_layout_nsAutoPtr_instantiation_400() { + fn __bindgen_test_layout_nsAutoPtr_instantiation_398() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( diff --git a/components/style/gecko/generated/structs_release.rs b/components/style/gecko/generated/structs_release.rs index bc786dafa11..3cfb3aa53e0 100644 --- a/components/style/gecko/generated/structs_release.rs +++ b/components/style/gecko/generated/structs_release.rs @@ -1033,6 +1033,16 @@ pub mod root { use self::super::super::root; #[repr(C)] #[derive(Debug, Copy, Clone)] + pub struct __is_swappable { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct __is_nothrow_swappable { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct pair<_T1, _T2> { pub first: _T1, pub second: _T2, @@ -1041,6 +1051,8 @@ pub mod root { } pub type pair_first_type<_T1> = _T1; pub type pair_second_type<_T2> = _T2; + pub type pair__PCCP = u8; + pub type pair__PCCFP = u8; #[repr(C)] #[derive(Debug, Copy)] pub struct input_iterator_tag { @@ -1070,10 +1082,17 @@ pub mod root { pub type iterator_pointer<_Pointer> = _Pointer; pub type iterator_reference<_Reference> = _Reference; #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct __iterator_traits { + pub _address: u8, + } + #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct iterator_traits { pub _address: u8, } #[repr(C)] + #[derive(Debug, Copy, Clone)] pub struct reverse_iterator<_Iterator> { pub current: _Iterator, pub _phantom_0: ::std::marker::PhantomData<::std::cell::UnsafeCell<_Iterator>>, @@ -1137,8 +1156,9 @@ pub mod root { root::nsSubstringTuple; pub type nsStringRepr_string_type = ::nsstring::nsStringRepr; pub type nsStringRepr_const_iterator = - root::nsReadingIterator; - pub type nsStringRepr_iterator = root::nsWritingIterator; + root::nsReadingIterator; + pub type nsStringRepr_iterator = + root::nsWritingIterator; pub type nsStringRepr_comparator_type = root::nsStringComparator; pub type nsStringRepr_char_iterator = *mut root::mozilla::detail::nsStringRepr_char_type; @@ -1228,9 +1248,9 @@ pub mod root { root::nsCSubstringTuple; pub type nsCStringRepr_string_type = root::nsCString; pub type nsCStringRepr_const_iterator = - root::nsReadingIterator<::std::os::raw::c_char>; + root::nsReadingIterator; pub type nsCStringRepr_iterator = - root::nsWritingIterator<::std::os::raw::c_char>; + root::nsWritingIterator; pub type nsCStringRepr_comparator_type = root::nsCStringComparator; pub type nsCStringRepr_char_iterator = @@ -10047,6 +10067,8 @@ pub mod root { PropertyStyleAnimationValuePair ) , "::" , stringify ! ( mValue ) )); } + pub type ComputedKeyframeValues = + root::nsTArray; #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_3() { assert_eq!(::std::mem::size_of::() , @@ -10303,6 +10325,36 @@ pub mod root { _unused: [u8; 0], } #[repr(C)] + pub struct ServoStyleSheetInner { + pub _base: root::mozilla::StyleSheetInfo, + pub mContents: root::RefPtr, + pub mURLData: root::RefPtr, + } + #[test] + fn bindgen_test_layout_ServoStyleSheetInner() { + assert_eq!(::std::mem::size_of::() , + 208usize , concat ! ( + "Size of: " , stringify ! ( ServoStyleSheetInner ) )); + assert_eq! (::std::mem::align_of::() , + 8usize , concat ! ( + "Alignment of " , stringify ! ( ServoStyleSheetInner ) + )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoStyleSheetInner ) ) . + mContents as * const _ as usize } , 192usize , concat + ! ( + "Alignment of field: " , stringify ! ( + ServoStyleSheetInner ) , "::" , stringify ! ( + mContents ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoStyleSheetInner ) ) . + mURLData as * const _ as usize } , 200usize , concat ! + ( + "Alignment of field: " , stringify ! ( + ServoStyleSheetInner ) , "::" , stringify ! ( mURLData + ) )); + } + #[repr(C)] #[derive(Debug)] pub struct URIPrincipalReferrerPolicyAndCORSModeHashKey { pub _base: root::nsURIHashKey, @@ -11151,6 +11203,26 @@ pub mod root { } #[repr(C)] #[derive(Debug)] + pub struct ServoMediaList { + pub _base: root::mozilla::dom::MediaList, + pub mRawList: root::RefPtr, + } + #[test] + fn bindgen_test_layout_ServoMediaList() { + assert_eq!(::std::mem::size_of::() , 56usize , + concat ! ( "Size of: " , stringify ! ( ServoMediaList ) + )); + assert_eq! (::std::mem::align_of::() , 8usize , + concat ! ( + "Alignment of " , stringify ! ( ServoMediaList ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const ServoMediaList ) ) . mRawList as + * const _ as usize } , 48usize , concat ! ( + "Alignment of field: " , stringify ! ( ServoMediaList + ) , "::" , stringify ! ( mRawList ) )); + } + #[repr(C)] + #[derive(Debug)] pub struct CSSFontFaceDescriptors { pub mFamily: root::nsCSSValue, pub mStyle: root::nsCSSValue, @@ -13898,6 +13970,11 @@ pub mod root { AutoSetAsyncStackForNewCalls ) , "::" , stringify ! ( oldAsyncCallIsExplicit ) )); } + pub type WarningReporter = + ::std::option::Option; #[repr(C)] #[derive(Debug)] pub struct AutoHideScriptedCaller { @@ -14051,6 +14128,141 @@ pub mod root { pub struct JSCompartment { _unused: [u8; 0], } + /** + * Describes a single error or warning that occurs in the execution of script. + */ + #[repr(C)] + pub struct JSErrorReport { + pub _base: root::JSErrorBase, + pub linebuf_: *const u16, + pub linebufLength_: usize, + pub tokenOffset_: usize, + pub notes: root::mozilla::UniquePtr, + pub flags: ::std::os::raw::c_uint, + pub exnType: i16, + pub _bitfield_1: u8, + pub __bindgen_padding_0: u8, + } + #[test] + fn bindgen_test_layout_JSErrorReport() { + assert_eq!(::std::mem::size_of::() , 72usize , concat ! + ( "Size of: " , stringify ! ( JSErrorReport ) )); + assert_eq! (::std::mem::align_of::() , 8usize , concat + ! ( "Alignment of " , stringify ! ( JSErrorReport ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . linebuf_ as * + const _ as usize } , 32usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( linebuf_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . linebufLength_ as + * const _ as usize } , 40usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( linebufLength_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . tokenOffset_ as * + const _ as usize } , 48usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( tokenOffset_ ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . notes as * const + _ as usize } , 56usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( notes ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . flags as * const + _ as usize } , 64usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( flags ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const JSErrorReport ) ) . exnType as * + const _ as usize } , 68usize , concat ! ( + "Alignment of field: " , stringify ! ( JSErrorReport ) , + "::" , stringify ! ( exnType ) )); + } + impl JSErrorReport { + #[inline] + pub fn isMuted(&self) -> bool { + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + let mask = 1u64 as u8; + let val = (unit_field_val & mask) >> 0usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_isMuted(&mut self, val: bool) { + let mask = 1u64 as u8; + let val = val as u8 as u8; + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + unit_field_val &= !mask; + unit_field_val |= (val << 0usize) & mask; + unsafe { + ::std::ptr::copy_nonoverlapping(&unit_field_val as *const _ as + *const u8, + &mut self._bitfield_1 as + *mut _ as *mut u8, + ::std::mem::size_of::()); + } + } + #[inline] + pub fn ownsLinebuf_(&self) -> bool { + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + let mask = 2u64 as u8; + let val = (unit_field_val & mask) >> 1usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_ownsLinebuf_(&mut self, val: bool) { + let mask = 2u64 as u8; + let val = val as u8 as u8; + let mut unit_field_val: u8 = + unsafe { ::std::mem::uninitialized() }; + unsafe { + ::std::ptr::copy_nonoverlapping(&self._bitfield_1 as *const _ + as *const u8, + &mut unit_field_val as *mut u8 + as *mut u8, + ::std::mem::size_of::()) + }; + unit_field_val &= !mask; + unit_field_val |= (val << 1usize) & mask; + unsafe { + ::std::ptr::copy_nonoverlapping(&unit_field_val as *const _ as + *const u8, + &mut self._bitfield_1 as + *mut _ as *mut u8, + ::std::mem::size_of::()); + } + } + #[inline] + pub fn new_bitfield_1(isMuted: bool, ownsLinebuf_: bool) -> u8 { + ({ ({ 0 } | ((isMuted as u8 as u8) << 0usize) & (1u64 as u8)) } | + ((ownsLinebuf_ as u8 as u8) << 1usize) & (2u64 as u8)) + } + } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct JSRuntime { @@ -15103,7 +15315,7 @@ pub mod root { #[derive(Debug)] pub struct gfxFontFeatureValueSet_ValueList { pub name: ::nsstring::nsStringRepr, - pub featureSelectors: root::nsTArray<::std::os::raw::c_uint>, + pub featureSelectors: root::nsTArray, } #[test] fn bindgen_test_layout_gfxFontFeatureValueSet_ValueList() { @@ -15208,7 +15420,7 @@ pub mod root { pub struct gfxFontFeatureValueSet_FeatureValueHashEntry { pub _base: root::PLDHashEntryHdr, pub mKey: root::gfxFontFeatureValueSet_FeatureValueHashKey, - pub mValues: root::nsTArray<::std::os::raw::c_uint>, + pub mValues: root::nsTArray, } pub type gfxFontFeatureValueSet_FeatureValueHashEntry_KeyType = *const root::gfxFontFeatureValueSet_FeatureValueHashKey; @@ -15311,7 +15523,7 @@ pub mod root { pub alternateValues: root::nsTArray, pub featureValueLookup: root::RefPtr, pub fontFeatureSettings: root::nsTArray, - pub fontVariationSettings: root::nsTArray, + pub fontVariationSettings: root::nsTArray, pub languageOverride: u32, } #[test] @@ -19103,7 +19315,7 @@ pub mod root { pub mUpgradeInsecurePreloads: bool, pub mHSTSPrimingURIList: [u64; 5usize], pub mDocumentContainer: u64, - pub mCharacterSet: root::mozilla::NotNull<*const root::mozilla::Encoding>, + pub mCharacterSet: root::mozilla::NotNull<*const root::nsIDocument_Encoding>, pub mCharacterSetSource: i32, pub mParentDocument: *mut root::nsIDocument, pub mCachedRootElement: *mut root::mozilla::dom::Element, @@ -19156,7 +19368,7 @@ pub mod root { */ pub mFrameRequestCallbackCounter: i32, pub mStaticCloneCount: u32, - pub mBlockedTrackingNodes: root::nsTArray, + pub mBlockedTrackingNodes: root::nsTArray, pub mWindow: *mut root::nsPIDOMWindowInner, pub mCachedEncoder: root::nsCOMPtr, pub mFrameRequestCallbacks: root::nsTArray, @@ -21936,6 +22148,11 @@ pub mod root { } } #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct nsBindingManager { + _unused: [u8; 0], + } + #[repr(C)] #[derive(Debug)] pub struct nsCSSCounterStyleRule { pub _base: root::mozilla::css::Rule, @@ -25288,11 +25505,6 @@ pub mod root { "Alignment of field: " , stringify ! ( nsNodeInfoManager ) , "::" , stringify ! ( mRecentlyUsedNodeInfos ) )); } - #[repr(C)] - #[derive(Debug, Copy, Clone)] - pub struct nsBindingManager { - _unused: [u8; 0], - } pub type NSPropertyFunc = ::std::option::Option, - pub mURI: root::RefPtr, + pub mURI: root::RefPtr, pub mListener: *mut root::imgINotificationObserver, pub mLoadGroup: root::nsCOMPtr, pub mLoadFlags: root::nsLoadFlags, @@ -32182,7 +32394,7 @@ pub mod root { pub mRefCnt: root::mozilla::ThreadSafeAutoRefCnt, pub mLoader: *mut root::imgLoader, pub mRequest: root::nsCOMPtr, - pub mURI: root::RefPtr, + pub mURI: root::RefPtr, pub mCurrentURI: root::nsCOMPtr, pub mLoadingPrincipal: root::nsCOMPtr, pub mPrincipal: root::nsCOMPtr, @@ -32209,8 +32421,8 @@ pub mod root { pub mImageErrorCode: root::nsresult, pub mBoostCategoriesRequested: u32, pub mMutex: root::mozilla::Mutex, - pub mProgressTracker: root::RefPtr, - pub mImage: root::RefPtr, + pub mProgressTracker: root::RefPtr, + pub mImage: root::RefPtr, pub _bitfield_1: u8, pub __bindgen_padding_0: [u8; 7usize], } @@ -33797,7 +34009,7 @@ pub mod root { ) , "::" , stringify ! ( mQuotePairs ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_86() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_80() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33808,7 +34020,7 @@ pub mod root { root::mozilla::StaticRefPtr ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_87() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_81() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -36065,7 +36277,7 @@ pub mod root { } #[repr(C)] #[derive(Debug, Copy, Clone)] - pub struct RawServoStyleSheet { + pub struct RawServoStyleSheetContents { _unused: [u8; 0], } #[repr(C)] @@ -36083,6 +36295,11 @@ pub mod root { pub struct RawServoAnimationValue { _unused: [u8; 0], } + #[repr(C)] + #[derive(Debug, Copy, Clone)] + pub struct RawServoMediaList { + _unused: [u8; 0], + } pub mod nsStyleTransformMatrix { #[allow(unused_imports)] use self::super::super::root; @@ -36105,7 +36322,7 @@ pub mod root { root::nsTArray>; pub type RawGeckoKeyframeList = root::nsTArray; pub type RawGeckoComputedKeyframeValuesList = - root::nsTArray>; + root::nsTArray; pub type RawGeckoStyleAnimationList = root::nsStyleAutoArray; pub type RawGeckoFontFaceRuleList = @@ -36952,48 +37169,48 @@ pub mod root { pub struct nsAttrValueOrString { _unused: [u8; 0], } - pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_1; pub const ELEMENT_HAS_ANIMATION_ONLY_DIRTY_DESCENDANTS_FOR_SERVO: - root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_85 + root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_79 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_3; + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_3; pub const ELEMENT_IS_POTENTIAL_ANIMATION_ONLY_RESTYLE_ROOT: - root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; - pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_PENDING_RESTYLE_FLAGS; - pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; - pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_ALL_RESTYLE_FLAGS; - pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_HAS_SCROLLGRAB; - pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_85 = - _bindgen_ty_85::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; + root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; + pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_PENDING_RESTYLE_FLAGS; + pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; + pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_ALL_RESTYLE_FLAGS; + pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_HAS_SCROLLGRAB; + pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_79 = + _bindgen_ty_79::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_85 { + pub enum _bindgen_ty_79 { ELEMENT_SHARED_RESTYLE_BIT_1 = 8388608, ELEMENT_SHARED_RESTYLE_BIT_2 = 16777216, ELEMENT_SHARED_RESTYLE_BIT_3 = 33554432, @@ -37544,6 +37761,22 @@ pub mod root { } #[repr(C)] #[derive(Debug, Copy)] + pub struct _bindgen_ty_29 { + pub _address: u8, + } + impl Clone for _bindgen_ty_29 { + fn clone(&self) -> Self { *self } + } + #[repr(C)] + #[derive(Debug, Copy)] + pub struct _bindgen_ty_30 { + pub _address: u8, + } + impl Clone for _bindgen_ty_30 { + fn clone(&self) -> Self { *self } + } + #[repr(C)] + #[derive(Debug, Copy)] pub struct __va_list_tag { pub gp_offset: ::std::os::raw::c_uint, pub fp_offset: ::std::os::raw::c_uint, @@ -37582,7 +37815,7 @@ pub mod root { } pub type __builtin_va_list = [root::__va_list_tag; 1usize]; #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_88() { + fn __bindgen_test_layout_IntegralConstant_instantiation_82() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -37591,7 +37824,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_89() { + fn __bindgen_test_layout_IntegralConstant_instantiation_83() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -37600,6 +37833,80 @@ pub mod root { ) )); } #[test] + fn __bindgen_test_layout_nsCharTraits_instantiation_84() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + } + #[test] + fn __bindgen_test_layout_nsReadingIterator_instantiation_85() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + } + #[test] + fn __bindgen_test_layout_nsWritingIterator_instantiation_86() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + } + #[test] + fn __bindgen_test_layout_nsCharTraits_instantiation_87() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCharTraits ) )); + } + #[test] + fn __bindgen_test_layout_nsReadingIterator_instantiation_88() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsReadingIterator + ) )); + } + #[test] + fn __bindgen_test_layout_nsWritingIterator_instantiation_89() { + assert_eq!(::std::mem::size_of::>() + , 24usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsWritingIterator + ) )); + } + #[test] fn __bindgen_test_layout_nsCharTraits_instantiation_90() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -37611,29 +37918,7 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_91() { - assert_eq!(::std::mem::size_of::>() , - 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsReadingIterator ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator ) )); - } - #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_92() { - assert_eq!(::std::mem::size_of::>() , - 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsWritingIterator ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator ) )); - } - #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_93() { + fn __bindgen_test_layout_nsCharTraits_instantiation_91() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37644,51 +37929,7 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_94() { - assert_eq!(::std::mem::size_of::>() - , 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); - } - #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_95() { - assert_eq!(::std::mem::size_of::>() - , 24usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - } - #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_96() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - } - #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_97() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCharTraits ) )); - } - #[test] - fn __bindgen_test_layout__bindgen_ty_id_211044_instantiation_98() { + fn __bindgen_test_layout__bindgen_ty_id_187383_instantiation_92() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -37697,7 +37938,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout__bindgen_ty_id_211080_instantiation_99() { + fn __bindgen_test_layout__bindgen_ty_id_187419_instantiation_93() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -37706,7 +37947,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_100() { + fn __bindgen_test_layout_nsTArray_instantiation_94() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37717,7 +37958,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_101() { + fn __bindgen_test_layout_Handle_instantiation_95() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37728,7 +37969,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_102() { + fn __bindgen_test_layout_Handle_instantiation_96() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37739,7 +37980,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_103() { + fn __bindgen_test_layout_Handle_instantiation_97() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37750,7 +37991,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_104() { + fn __bindgen_test_layout_MutableHandle_instantiation_98() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37761,7 +38002,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_105() { + fn __bindgen_test_layout_Rooted_instantiation_99() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37772,7 +38013,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_106() { + fn __bindgen_test_layout_DeletePolicy_instantiation_100() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37783,7 +38024,7 @@ pub mod root { root::JS::DeletePolicy ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_107() { + fn __bindgen_test_layout_nsTArray_instantiation_101() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37794,7 +38035,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_108() { + fn __bindgen_test_layout_nsTArray_instantiation_102() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37805,29 +38046,29 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_109() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_103() { + assert_eq!(::std::mem::size_of::>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::nsTArray ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_110() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_104() { + assert_eq!(::std::mem::size_of::>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::nsTArray ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_PointTyped_instantiation_111() { + fn __bindgen_test_layout_PointTyped_instantiation_105() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37838,7 +38079,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_112() { + fn __bindgen_test_layout_IntPointTyped_instantiation_106() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37849,7 +38090,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SizeTyped_instantiation_113() { + fn __bindgen_test_layout_SizeTyped_instantiation_107() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37860,7 +38101,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_114() { + fn __bindgen_test_layout_RectTyped_instantiation_108() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37871,7 +38112,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_115() { + fn __bindgen_test_layout_IntPointTyped_instantiation_109() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37882,7 +38123,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntSizeTyped_instantiation_116() { + fn __bindgen_test_layout_IntSizeTyped_instantiation_110() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37893,7 +38134,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_117() { + fn __bindgen_test_layout_IntRectTyped_instantiation_111() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37904,7 +38145,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_MarginTyped_instantiation_118() { + fn __bindgen_test_layout_MarginTyped_instantiation_112() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37915,7 +38156,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_119() { + fn __bindgen_test_layout_RectTyped_instantiation_113() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37926,7 +38167,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_120() { + fn __bindgen_test_layout_IntRectTyped_instantiation_114() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37937,7 +38178,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactor_instantiation_121() { + fn __bindgen_test_layout_ScaleFactor_instantiation_115() { assert_eq!(::std::mem::size_of::() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -37946,7 +38187,7 @@ pub mod root { u32 ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_122() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_116() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37957,7 +38198,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_123() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_117() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37968,7 +38209,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_124() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_118() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37979,7 +38220,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_125() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_119() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -37990,7 +38231,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_126() { + fn __bindgen_test_layout_already_AddRefed_instantiation_120() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38001,7 +38242,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_127() { + fn __bindgen_test_layout_already_AddRefed_instantiation_121() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38012,7 +38253,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_128() { + fn __bindgen_test_layout_RefPtr_instantiation_122() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38023,7 +38264,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_129() { + fn __bindgen_test_layout_nsTArray_instantiation_123() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38036,7 +38277,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_130() { + fn __bindgen_test_layout_RefPtr_instantiation_124() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38047,7 +38288,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_131() { + fn __bindgen_test_layout_nsTArray_instantiation_125() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38060,7 +38301,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_WeakPtr_instantiation_132() { + fn __bindgen_test_layout_WeakPtr_instantiation_126() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -38069,7 +38310,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_133() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_127() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38080,7 +38321,7 @@ pub mod root { root::nsPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_134() { + fn __bindgen_test_layout_nsTArray_instantiation_128() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38091,7 +38332,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_135() { + fn __bindgen_test_layout_TErrorResult_instantiation_129() { assert_eq!(::std::mem::size_of::() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38102,7 +38343,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_136() { + fn __bindgen_test_layout_TErrorResult_instantiation_130() { assert_eq!(::std::mem::size_of::() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38113,7 +38354,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_137() { + fn __bindgen_test_layout_already_AddRefed_instantiation_131() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38124,6 +38365,72 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_132() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_133() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_134() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_135() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_136() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_RefPtr_instantiation_137() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::RefPtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::RefPtr ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_138() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -38135,18 +38442,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_139() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_140() { + fn __bindgen_test_layout_Handle_instantiation_139() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38157,62 +38453,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_141() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::StyleSheet> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::StyleSheet> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_142() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_143() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::RefPtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::RefPtr ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_144() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_145() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_146() { + fn __bindgen_test_layout_already_AddRefed_instantiation_140() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38223,7 +38464,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_147() { + fn __bindgen_test_layout_already_AddRefed_instantiation_141() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38234,7 +38475,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_148() { + fn __bindgen_test_layout_already_AddRefed_instantiation_142() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38245,7 +38486,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_149() { + fn __bindgen_test_layout_Handle_instantiation_143() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38256,7 +38497,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_150() { + fn __bindgen_test_layout_MutableHandle_instantiation_144() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38267,7 +38508,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_151() { + fn __bindgen_test_layout_MutableHandle_instantiation_145() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38278,6 +38519,72 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] + fn __bindgen_test_layout_DeletePolicy_instantiation_146() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_147() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] + fn __bindgen_test_layout_DeletePolicy_instantiation_148() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_149() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] + fn __bindgen_test_layout_DeletePolicy_instantiation_150() { + assert_eq!(::std::mem::size_of::() , 1usize , + concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + assert_eq!(::std::mem::align_of::() , 1usize , + concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::DeletePolicy ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_151() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] fn __bindgen_test_layout_DeletePolicy_instantiation_152() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -38312,28 +38619,6 @@ pub mod root { } #[test] fn __bindgen_test_layout_UniquePtr_instantiation_155() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_156() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_157() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38344,51 +38629,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_158() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_159() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_160() { - assert_eq!(::std::mem::size_of::() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_161() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_iterator_instantiation_162() { + fn __bindgen_test_layout_iterator_instantiation_156() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38399,7 +38640,7 @@ pub mod root { root::std::iterator ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_163() { + fn __bindgen_test_layout_DeletePolicy_instantiation_157() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38410,7 +38651,7 @@ pub mod root { root::JS::DeletePolicy ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_164() { + fn __bindgen_test_layout_UniquePtr_instantiation_158() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38421,7 +38662,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_165() { + fn __bindgen_test_layout_DeletePolicy_instantiation_159() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38432,7 +38673,7 @@ pub mod root { root::JS::DeletePolicy ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_166() { + fn __bindgen_test_layout_UniquePtr_instantiation_160() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38443,7 +38684,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_167() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_161() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38454,7 +38695,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_168() { + fn __bindgen_test_layout_Handle_instantiation_162() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38465,7 +38706,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_169() { + fn __bindgen_test_layout_MutableHandle_instantiation_163() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38476,7 +38717,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_170() { + fn __bindgen_test_layout_nsTArray_instantiation_164() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38487,7 +38728,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_171() { + fn __bindgen_test_layout_nsTArray_instantiation_165() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38498,7 +38739,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_172() { + fn __bindgen_test_layout_Heap_instantiation_166() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38509,7 +38750,7 @@ pub mod root { root::JS::Heap ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_173() { + fn __bindgen_test_layout_Heap_instantiation_167() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38520,7 +38761,7 @@ pub mod root { root::JS::Heap<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_TenuredHeap_instantiation_174() { + fn __bindgen_test_layout_TenuredHeap_instantiation_168() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38531,7 +38772,7 @@ pub mod root { root::JS::TenuredHeap ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_175() { + fn __bindgen_test_layout_already_AddRefed_instantiation_169() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38542,20 +38783,20 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_176() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_170() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIDocument_Encoding> ) )); - assert_eq!(::std::mem::align_of::>() + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIDocument_Encoding> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_177() { + fn __bindgen_test_layout_nsTArray_instantiation_171() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38568,7 +38809,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_178() { + fn __bindgen_test_layout_RefPtr_instantiation_172() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38579,7 +38820,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_179() { + fn __bindgen_test_layout_nsTArray_instantiation_173() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38592,7 +38833,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_180() { + fn __bindgen_test_layout_RefPtr_instantiation_174() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38603,7 +38844,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_181() { + fn __bindgen_test_layout_nsTArray_instantiation_175() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38616,18 +38857,18 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_182() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_176() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray<*mut root::nsIDocument_Element> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); + root::nsTArray<*mut root::nsIDocument_Element> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_183() { + fn __bindgen_test_layout_RefPtr_instantiation_177() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38638,7 +38879,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_184() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_178() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38649,7 +38890,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_185() { + fn __bindgen_test_layout_nsTArray_instantiation_179() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38660,7 +38901,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_186() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_180() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38671,7 +38912,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_187() { + fn __bindgen_test_layout_already_AddRefed_instantiation_181() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38682,7 +38923,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_188() { + fn __bindgen_test_layout_already_AddRefed_instantiation_182() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38693,7 +38934,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_189() { + fn __bindgen_test_layout_RefPtr_instantiation_183() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38704,18 +38945,18 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_190() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_nsTArray_instantiation_184() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); - assert_eq!(::std::mem::align_of::>() + root::nsTArray<*mut root::nsIDocument_Element> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::mozilla::dom::Element> ) )); + root::nsTArray<*mut root::nsIDocument_Element> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_191() { + fn __bindgen_test_layout_already_AddRefed_instantiation_185() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38726,7 +38967,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_192() { + fn __bindgen_test_layout_MutableHandle_instantiation_186() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38737,7 +38978,7 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_193() { + fn __bindgen_test_layout_already_AddRefed_instantiation_187() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38748,7 +38989,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_194() { + fn __bindgen_test_layout_already_AddRefed_instantiation_188() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38759,7 +39000,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_195() { + fn __bindgen_test_layout_already_AddRefed_instantiation_189() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38770,7 +39011,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_196() { + fn __bindgen_test_layout_RefPtr_instantiation_190() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38781,7 +39022,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_197() { + fn __bindgen_test_layout_Handle_instantiation_191() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38792,7 +39033,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_198() { + fn __bindgen_test_layout_already_AddRefed_instantiation_192() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38803,7 +39044,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_199() { + fn __bindgen_test_layout_already_AddRefed_instantiation_193() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38814,7 +39055,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_200() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_194() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38825,18 +39066,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_201() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - assert_eq!(::std::mem::align_of::() , 8usize , concat - ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - } - #[test] - fn __bindgen_test_layout_RefPtr_instantiation_202() { + fn __bindgen_test_layout_RefPtr_instantiation_195() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38847,7 +39077,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_203() { + fn __bindgen_test_layout_nsTArray_instantiation_196() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38860,6 +39090,83 @@ pub mod root { )); } #[test] + fn __bindgen_test_layout_nsTArray_instantiation_197() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::mozilla::StyleSheet> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_198() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_199() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_200() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_201() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_202() { + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<::nsstring::nsStringRepr> ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<::nsstring::nsStringRepr> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_203() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_204() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -38871,51 +39178,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_205() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_206() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_207() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_208() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_209() { + fn __bindgen_test_layout_Handle_instantiation_205() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38926,29 +39189,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_210() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_211() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_212() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_206() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38961,7 +39202,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_213() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_207() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38972,7 +39213,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_214() { + fn __bindgen_test_layout_Handle_instantiation_208() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38983,7 +39224,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_215() { + fn __bindgen_test_layout_nsTArray_instantiation_209() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -38994,7 +39235,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_216() { + fn __bindgen_test_layout_nsTArray_instantiation_210() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39005,7 +39246,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_217() { + fn __bindgen_test_layout_already_AddRefed_instantiation_211() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39016,7 +39257,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_218() { + fn __bindgen_test_layout_already_AddRefed_instantiation_212() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39027,7 +39268,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_219() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_213() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -39036,7 +39277,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_220() { + fn __bindgen_test_layout_already_AddRefed_instantiation_214() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39047,7 +39288,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_221() { + fn __bindgen_test_layout_nsTArray_instantiation_215() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39058,33 +39299,33 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_222() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_216() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_223() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_217() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::mozilla::NotNull<*const root::nsPresContext_Encoding> + ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_224() { + fn __bindgen_test_layout_already_AddRefed_instantiation_218() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39095,7 +39336,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_225() { + fn __bindgen_test_layout_DefaultDelete_instantiation_219() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39106,7 +39347,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_226() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_220() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39117,7 +39358,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_227() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_221() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39128,7 +39369,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_228() { + fn __bindgen_test_layout_nsTArray_instantiation_222() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39139,7 +39380,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_229() { + fn __bindgen_test_layout_already_AddRefed_instantiation_223() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39150,7 +39391,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_230() { + fn __bindgen_test_layout_already_AddRefed_instantiation_224() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39161,7 +39402,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_231() { + fn __bindgen_test_layout_already_AddRefed_instantiation_225() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39172,26 +39413,92 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_226() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_227() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_228() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_229() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_230() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_231() { + assert_eq!(::std::mem::size_of::<[u64; 30usize]>() , 240usize , concat + ! ( + "Size of template specialization: " , stringify ! ( + [u64; 30usize] ) )); + assert_eq!(::std::mem::align_of::<[u64; 30usize]>() , 8usize , concat + ! ( + "Alignment of template specialization: " , stringify ! ( + [u64; 30usize] ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_232() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_233() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_233() { + assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! + ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + [u64; 5usize] ) )); + assert_eq!(::std::mem::align_of::<[u64; 5usize]>() , 8usize , concat ! + ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + [u64; 5usize] ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_234() { @@ -39205,15 +39512,15 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_235() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_235() { + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::nsTArray<::nsstring::nsStringRepr> ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); + root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_236() { @@ -39227,59 +39534,59 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_237() { - assert_eq!(::std::mem::size_of::<[u64; 30usize]>() , 240usize , concat - ! ( - "Size of template specialization: " , stringify ! ( - [u64; 30usize] ) )); - assert_eq!(::std::mem::align_of::<[u64; 30usize]>() , 8usize , concat - ! ( - "Alignment of template specialization: " , stringify ! ( - [u64; 30usize] ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_238() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_OwningNonNull_instantiation_237() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::OwningNonNull ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); + root::mozilla::OwningNonNull ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_239() { - assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! - ( + fn __bindgen_test_layout_OwningNonNull_instantiation_238() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - [u64; 5usize] ) )); - assert_eq!(::std::mem::align_of::<[u64; 5usize]>() , 8usize , concat ! - ( + root::mozilla::OwningNonNull ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - [u64; 5usize] ) )); + root::mozilla::OwningNonNull ) )); + } + #[test] + fn __bindgen_test_layout_OwningNonNull_instantiation_239() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::OwningNonNull ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::OwningNonNull ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_240() { - assert_eq!(::std::mem::size_of::>() + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); + root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_241() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( + fn __bindgen_test_layout_Handle_instantiation_241() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::nsstring::nsStringRepr> ) )); + root::JS::Handle ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_242() { @@ -39293,59 +39600,59 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_243() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_MutableHandle_instantiation_243() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); + root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_244() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + fn __bindgen_test_layout_Handle_instantiation_244() { + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); + root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_245() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_MutableHandle_instantiation_245() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::OwningNonNull ) )); + root::JS::MutableHandle ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_246() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( + assert_eq!(::std::mem::size_of::>() , + 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() , + 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); + root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_247() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_MutableHandle_instantiation_247() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); + root::JS::MutableHandle ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_248() { @@ -39359,95 +39666,29 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_249() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_Handle_instantiation_249() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] fn __bindgen_test_layout_Handle_instantiation_250() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); + root::JS::Handle<*mut root::JSObject> ) )); } #[test] fn __bindgen_test_layout_MutableHandle_instantiation_251() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_252() { - assert_eq!(::std::mem::size_of::>() , - 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() , - 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_253() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_254() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_255() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_256() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_257() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39458,7 +39699,7 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_258() { + fn __bindgen_test_layout_RefPtr_instantiation_252() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39469,7 +39710,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_259() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_253() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39480,7 +39721,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_260() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_254() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39491,7 +39732,7 @@ pub mod root { root::nsPtrHashKey<::std::os::raw::c_void> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_261() { + fn __bindgen_test_layout_already_AddRefed_instantiation_255() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39502,7 +39743,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_262() { + fn __bindgen_test_layout_already_AddRefed_instantiation_256() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39513,20 +39754,20 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_263() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_257() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); - assert_eq!(::std::mem::align_of::>() + root::mozilla::NotNull<*const root::nsLanguageAtomService_Encoding> + ) )); + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) - )); + root::mozilla::NotNull<*const root::nsLanguageAtomService_Encoding> + ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_264() { + fn __bindgen_test_layout_already_AddRefed_instantiation_258() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39537,7 +39778,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_265() { + fn __bindgen_test_layout_already_AddRefed_instantiation_259() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39548,7 +39789,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_266() { + fn __bindgen_test_layout_already_AddRefed_instantiation_260() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39559,7 +39800,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_267() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_261() { assert_eq!(::std::mem::size_of::<[u64; 30usize]>() , 240usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39570,7 +39811,7 @@ pub mod root { [u64; 30usize] ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_268() { + fn __bindgen_test_layout_MutableHandle_instantiation_262() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39581,7 +39822,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_269() { + fn __bindgen_test_layout_MutableHandle_instantiation_263() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39592,7 +39833,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_270() { + fn __bindgen_test_layout_already_AddRefed_instantiation_264() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39603,7 +39844,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_271() { + fn __bindgen_test_layout_DefaultDelete_instantiation_265() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39614,7 +39855,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_272() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_266() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39625,7 +39866,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_273() { + fn __bindgen_test_layout_Rooted_instantiation_267() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39636,7 +39877,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_274() { + fn __bindgen_test_layout_Rooted_instantiation_268() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39647,7 +39888,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_275() { + fn __bindgen_test_layout_already_AddRefed_instantiation_269() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39658,7 +39899,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_276() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_270() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39669,7 +39910,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_277() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_271() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39680,20 +39921,20 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_NotNull_instantiation_278() { - assert_eq!(::std::mem::size_of::>() + fn __bindgen_test_layout_NotNull_instantiation_272() { + assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIParser_Encoding> ) )); - assert_eq!(::std::mem::align_of::>() + assert_eq!(::std::mem::align_of::>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::mozilla::NotNull<*const root::mozilla::Encoding> ) + root::mozilla::NotNull<*const root::nsIParser_Encoding> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_279() { + fn __bindgen_test_layout_nsTArray_instantiation_273() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39704,7 +39945,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_280() { + fn __bindgen_test_layout_Handle_instantiation_274() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39715,7 +39956,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_281() { + fn __bindgen_test_layout_MutableHandle_instantiation_275() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39726,7 +39967,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_282() { + fn __bindgen_test_layout_Handle_instantiation_276() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39737,7 +39978,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_283() { + fn __bindgen_test_layout_MutableHandle_instantiation_277() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39748,7 +39989,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_284() { + fn __bindgen_test_layout_nsTArray_instantiation_278() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39759,7 +40000,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_285() { + fn __bindgen_test_layout_Handle_instantiation_279() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39770,7 +40011,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_286() { + fn __bindgen_test_layout_RefPtr_instantiation_280() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39781,7 +40022,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_287() { + fn __bindgen_test_layout_RefPtr_instantiation_281() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39792,7 +40033,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_288() { + fn __bindgen_test_layout_RefPtr_instantiation_282() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39803,7 +40044,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_289() { + fn __bindgen_test_layout_nsTArray_instantiation_283() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39816,7 +40057,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_290() { + fn __bindgen_test_layout_RefPtr_instantiation_284() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39827,7 +40068,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_291() { + fn __bindgen_test_layout_already_AddRefed_instantiation_285() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39838,7 +40079,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_292() { + fn __bindgen_test_layout_already_AddRefed_instantiation_286() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39849,7 +40090,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_293() { + fn __bindgen_test_layout_Handle_instantiation_287() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39860,7 +40101,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_294() { + fn __bindgen_test_layout_nsTArray_instantiation_288() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39871,7 +40112,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_295() { + fn __bindgen_test_layout_RefPtr_instantiation_289() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39884,7 +40125,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_296() { + fn __bindgen_test_layout_nsTArray_instantiation_290() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39897,7 +40138,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_297() { + fn __bindgen_test_layout_RefPtr_instantiation_291() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39910,7 +40151,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_298() { + fn __bindgen_test_layout_UniquePtr_instantiation_292() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39921,7 +40162,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_299() { + fn __bindgen_test_layout_nsTArray_instantiation_293() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39932,7 +40173,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_300() { + fn __bindgen_test_layout_Handle_instantiation_294() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39943,7 +40184,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_301() { + fn __bindgen_test_layout_MutableHandle_instantiation_295() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39954,7 +40195,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_302() { + fn __bindgen_test_layout_Handle_instantiation_296() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39965,7 +40206,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_303() { + fn __bindgen_test_layout_MutableHandle_instantiation_297() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39976,7 +40217,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_304() { + fn __bindgen_test_layout_already_AddRefed_instantiation_298() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39987,7 +40228,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_305() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_299() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -39998,7 +40239,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_306() { + fn __bindgen_test_layout_OwningNonNull_instantiation_300() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40011,7 +40252,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_307() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_301() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40022,7 +40263,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_308() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_302() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40033,7 +40274,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_309() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_303() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40044,7 +40285,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_310() { + fn __bindgen_test_layout_DefaultDelete_instantiation_304() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40055,6 +40296,72 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_305() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_306() { + assert_eq!(::std::mem::size_of::>() + , 40usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsMainThreadPtrHolder ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsMainThreadPtrHolder ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_307() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_308() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_309() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_310() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_311() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40066,73 +40373,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_312() { - assert_eq!(::std::mem::size_of::>() - , 40usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsMainThreadPtrHolder ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsMainThreadPtrHolder ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_313() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_314() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_315() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_316() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_317() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_318() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_312() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40143,7 +40384,7 @@ pub mod root { root::nsPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_319() { + fn __bindgen_test_layout_already_AddRefed_instantiation_313() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40154,7 +40395,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_320() { + fn __bindgen_test_layout_DefaultDelete_instantiation_314() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40165,7 +40406,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_321() { + fn __bindgen_test_layout_UniquePtr_instantiation_315() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40176,7 +40417,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_322() { + fn __bindgen_test_layout_DefaultDelete_instantiation_316() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40187,7 +40428,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_323() { + fn __bindgen_test_layout_UniquePtr_instantiation_317() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40198,7 +40439,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_324() { + fn __bindgen_test_layout_already_AddRefed_instantiation_318() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40209,7 +40450,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_325() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_319() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -40218,7 +40459,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_326() { + fn __bindgen_test_layout_nsTArray_instantiation_320() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40229,7 +40470,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_327() { + fn __bindgen_test_layout_nsTArray_instantiation_321() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40240,7 +40481,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_328() { + fn __bindgen_test_layout_already_AddRefed_instantiation_322() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40251,7 +40492,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_329() { + fn __bindgen_test_layout_already_AddRefed_instantiation_323() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40262,7 +40503,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_330() { + fn __bindgen_test_layout_Maybe_instantiation_324() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40273,7 +40514,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_331() { + fn __bindgen_test_layout_Maybe_instantiation_325() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40284,7 +40525,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_332() { + fn __bindgen_test_layout_already_AddRefed_instantiation_326() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40295,7 +40536,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_333() { + fn __bindgen_test_layout_already_AddRefed_instantiation_327() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40306,6 +40547,72 @@ pub mod root { root::already_AddRefed ) )); } #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_328() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_329() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] + fn __bindgen_test_layout_DefaultDelete_instantiation_330() { + assert_eq!(::std::mem::size_of::() , + 1usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + assert_eq!(::std::mem::align_of::() , + 1usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::DefaultDelete ) )); + } + #[test] + fn __bindgen_test_layout_UniquePtr_instantiation_331() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::mozilla::UniquePtr ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_332() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_Maybe_instantiation_333() { + assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! + ( + "Size of template specialization: " , stringify ! ( + [u32; 3usize] ) )); + assert_eq!(::std::mem::align_of::<[u32; 3usize]>() , 4usize , concat ! + ( + "Alignment of template specialization: " , stringify ! ( + [u32; 3usize] ) )); + } + #[test] fn __bindgen_test_layout_DefaultDelete_instantiation_334() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( @@ -40317,18 +40624,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_335() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_336() { + fn __bindgen_test_layout_DefaultDelete_instantiation_335() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40339,62 +40635,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_337() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::UniquePtr ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_338() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_Maybe_instantiation_339() { - assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - [u32; 3usize] ) )); - assert_eq!(::std::mem::align_of::<[u32; 3usize]>() , 4usize , concat ! - ( - "Alignment of template specialization: " , stringify ! ( - [u32; 3usize] ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_340() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_341() { - assert_eq!(::std::mem::size_of::() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_pair_instantiation_342() { + fn __bindgen_test_layout_pair_instantiation_336() { assert_eq!(::std::mem::size_of::>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40405,7 +40646,7 @@ pub mod root { root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_343() { + fn __bindgen_test_layout_nsTArray_instantiation_337() { assert_eq!(::std::mem::size_of::>>() , 8usize , concat ! ( @@ -40420,7 +40661,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_344() { + fn __bindgen_test_layout_already_AddRefed_instantiation_338() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40431,7 +40672,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_345() { + fn __bindgen_test_layout_nsTArray_instantiation_339() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40442,7 +40683,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_346() { + fn __bindgen_test_layout_nsTArray_instantiation_340() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40453,7 +40694,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_347() { + fn __bindgen_test_layout_nsTArray_instantiation_341() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40464,7 +40705,7 @@ pub mod root { root::nsTArray ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_348() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_342() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40475,7 +40716,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_349() { + fn __bindgen_test_layout_RefPtr_instantiation_343() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40486,7 +40727,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_nsStyleAutoArray_instantiation_350() { + fn __bindgen_test_layout_nsStyleAutoArray_instantiation_344() { assert_eq!(::std::mem::size_of::>() , 64usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40497,7 +40738,7 @@ pub mod root { root::nsStyleAutoArray ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_351() { + fn __bindgen_test_layout_DefaultDelete_instantiation_345() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40508,7 +40749,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_352() { + fn __bindgen_test_layout_UniquePtr_instantiation_346() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40519,7 +40760,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_353() { + fn __bindgen_test_layout_DefaultDelete_instantiation_347() { assert_eq!(::std::mem::size_of::() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40530,7 +40771,7 @@ pub mod root { root::mozilla::DefaultDelete ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_354() { + fn __bindgen_test_layout_UniquePtr_instantiation_348() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40541,7 +40782,7 @@ pub mod root { root::mozilla::UniquePtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_355() { + fn __bindgen_test_layout_RefPtr_instantiation_349() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40552,7 +40793,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_356() { + fn __bindgen_test_layout_RefPtr_instantiation_350() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40563,7 +40804,7 @@ pub mod root { root::RefPtr ) )); } #[test] - fn __bindgen_test_layout_NonNull_instantiation_357() { + fn __bindgen_test_layout_NonNull_instantiation_351() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40576,7 +40817,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_NonNull_instantiation_358() { + fn __bindgen_test_layout_NonNull_instantiation_352() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40589,7 +40830,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_359() { + fn __bindgen_test_layout_Handle_instantiation_353() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40600,7 +40841,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_360() { + fn __bindgen_test_layout_MutableHandle_instantiation_354() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40611,7 +40852,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_361() { + fn __bindgen_test_layout_Maybe_instantiation_355() { assert_eq!(::std::mem::size_of::<[u64; 18usize]>() , 144usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40622,7 +40863,7 @@ pub mod root { [u64; 18usize] ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_362() { + fn __bindgen_test_layout_Maybe_instantiation_356() { assert_eq!(::std::mem::size_of::<[u64; 18usize]>() , 144usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40633,7 +40874,7 @@ pub mod root { [u64; 18usize] ) )); } #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_363() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_357() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40644,7 +40885,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_364() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_358() { assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40655,6 +40896,74 @@ pub mod root { root::nsCOMPtr ) )); } #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_359() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_already_AddRefed_instantiation_360() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::already_AddRefed ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_361() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + } + #[test] + fn __bindgen_test_layout_nsTArray_instantiation_362() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsTArray<*mut root::nsIContent> ) )); + } + #[test] + fn __bindgen_test_layout_nsCOMPtr_instantiation_363() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! + ( + "Size of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + assert_eq!(::std::mem::align_of::() , 8usize , concat + ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + } + #[test] + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_364() { + assert_eq!(::std::mem::size_of::>() + , 16usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsRefPtrHashKey + ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsRefPtrHashKey + ) )); + } + #[test] fn __bindgen_test_layout_already_AddRefed_instantiation_365() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40666,75 +40975,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_366() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_367() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_368() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsTArray<*mut root::nsIContent> ) )); - } - #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_369() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - assert_eq!(::std::mem::align_of::() , 8usize , concat - ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - } - #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_370() { - assert_eq!(::std::mem::size_of::>() - , 16usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsRefPtrHashKey - ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsRefPtrHashKey - ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_371() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::already_AddRefed ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_372() { + fn __bindgen_test_layout_nsTArray_instantiation_366() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40747,7 +40988,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_373() { + fn __bindgen_test_layout_Handle_instantiation_367() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40758,7 +40999,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_374() { + fn __bindgen_test_layout_Handle_instantiation_368() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40769,7 +41010,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_375() { + fn __bindgen_test_layout_RefPtr_instantiation_369() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40780,6 +41021,66 @@ pub mod root { root::RefPtr ) )); } #[test] + fn __bindgen_test_layout_Handle_instantiation_370() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_371() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::MutableHandle ) )); + } + #[test] + fn __bindgen_test_layout_Sequence_instantiation_372() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( u64 ) + )); + assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + u64 ) )); + } + #[test] + fn __bindgen_test_layout_Handle_instantiation_373() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle ) )); + } + #[test] + fn __bindgen_test_layout_Sequence_instantiation_374() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( u64 ) + )); + assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + u64 ) )); + } + #[test] + fn __bindgen_test_layout_Sequence_instantiation_375() { + assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( u64 ) + )); + assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + u64 ) )); + } + #[test] fn __bindgen_test_layout_Handle_instantiation_376() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40791,7 +41092,18 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_377() { + fn __bindgen_test_layout_Handle_instantiation_377() { + assert_eq!(::std::mem::size_of::>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + assert_eq!(::std::mem::align_of::>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::JS::Handle<*mut root::JSObject> ) )); + } + #[test] + fn __bindgen_test_layout_MutableHandle_instantiation_378() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40802,15 +41114,6 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Sequence_instantiation_378() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( u64 ) - )); - assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - u64 ) )); - } - #[test] fn __bindgen_test_layout_Handle_instantiation_379() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( @@ -40822,47 +41125,7 @@ pub mod root { root::JS::Handle ) )); } #[test] - fn __bindgen_test_layout_Sequence_instantiation_380() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( u64 ) - )); - assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - u64 ) )); - } - #[test] - fn __bindgen_test_layout_Sequence_instantiation_381() { - assert_eq!(::std::mem::size_of::() , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( u64 ) - )); - assert_eq!(::std::mem::align_of::() , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - u64 ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_382() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_383() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle<*mut root::JSObject> ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_384() { + fn __bindgen_test_layout_MutableHandle_instantiation_380() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40873,29 +41136,7 @@ pub mod root { root::JS::MutableHandle ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_385() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::Handle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::Handle ) )); - } - #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_386() { - assert_eq!(::std::mem::size_of::>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - assert_eq!(::std::mem::align_of::>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::MutableHandle ) )); - } - #[test] - fn __bindgen_test_layout_Handle_instantiation_387() { + fn __bindgen_test_layout_Handle_instantiation_381() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40906,7 +41147,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_388() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_382() { assert_eq!(::std::mem::size_of::>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40917,7 +41158,7 @@ pub mod root { root::nsRefPtrHashKey ) )); } #[test] - fn __bindgen_test_layout_nsClassHashtable_instantiation_389() { + fn __bindgen_test_layout_nsClassHashtable_instantiation_383() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40928,7 +41169,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_390() { + fn __bindgen_test_layout_Handle_instantiation_384() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40939,7 +41180,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_391() { + fn __bindgen_test_layout_nsTArray_instantiation_385() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40950,7 +41191,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_392() { + fn __bindgen_test_layout_nsTArray_instantiation_386() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40961,7 +41202,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_393() { + fn __bindgen_test_layout_nsTArray_instantiation_387() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40972,7 +41213,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_394() { + fn __bindgen_test_layout_already_AddRefed_instantiation_388() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40983,7 +41224,7 @@ pub mod root { root::already_AddRefed ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_395() { + fn __bindgen_test_layout_Handle_instantiation_389() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -40994,7 +41235,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_396() { + fn __bindgen_test_layout_nsTArray_instantiation_390() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -41005,7 +41246,7 @@ pub mod root { root::nsTArray<*mut root::mozilla::css::DocumentRule> ) )); } #[test] - fn __bindgen_test_layout_nsAutoPtr_instantiation_397() { + fn __bindgen_test_layout_nsAutoPtr_instantiation_391() { assert_eq!(::std::mem::size_of::>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( diff --git a/components/style/invalidation/media_queries.rs b/components/style/invalidation/media_queries.rs index 46eca61a3a1..73b8f6a60b8 100644 --- a/components/style/invalidation/media_queries.rs +++ b/components/style/invalidation/media_queries.rs @@ -27,6 +27,13 @@ use stylesheets::{NestedRuleIterationCondition, Stylesheet}; #[cfg_attr(feature = "servo", derive(HeapSizeOf))] pub struct MediaListKey(usize); +impl MediaListKey { + /// Create a MediaListKey from a raw usize. + pub fn from_raw(k: usize) -> Self { + MediaListKey(k) + } +} + /// A trait to get a given `MediaListKey` for a given item that can hold a /// `MediaList`. pub trait ToMediaListKey : Sized { diff --git a/components/style/invalidation/stylesheets.rs b/components/style/invalidation/stylesheets.rs index b28ae6fed87..9540482786c 100644 --- a/components/style/invalidation/stylesheets.rs +++ b/components/style/invalidation/stylesheets.rs @@ -15,7 +15,7 @@ use selector_parser::SelectorImpl; use selectors::attr::CaseSensitivity; use selectors::parser::{Component, Selector}; use shared_lock::SharedRwLockReadGuard; -use stylesheets::{CssRule, Stylesheet}; +use stylesheets::{CssRule, StylesheetInDocument}; use stylist::Stylist; /// An invalidation scope represents a kind of subtree that may need to be @@ -80,11 +80,14 @@ impl StylesheetInvalidationSet { /// Analyze the given stylesheet, and collect invalidations from their /// rules, in order to avoid doing a full restyle when we style the document /// next time. - pub fn collect_invalidations_for( + pub fn collect_invalidations_for( &mut self, stylist: &Stylist, - stylesheet: &Stylesheet, - guard: &SharedRwLockReadGuard) + stylesheet: &S, + guard: &SharedRwLockReadGuard + ) + where + S: StylesheetInDocument, { debug!("StylesheetInvalidationSet::collect_invalidations_for"); if self.fully_invalid { @@ -92,7 +95,7 @@ impl StylesheetInvalidationSet { return; } - if stylesheet.disabled() || + if !stylesheet.enabled() || !stylesheet.is_effective_for_device(stylist.device(), guard) { debug!(" > Stylesheet was not effective"); return; // Nothing to do here. diff --git a/components/style/shared_lock.rs b/components/style/shared_lock.rs index 564050ca552..1a4ec7c9f20 100644 --- a/components/style/shared_lock.rs +++ b/components/style/shared_lock.rs @@ -228,6 +228,18 @@ pub trait ToCssWithGuard { } } +/// Parameters needed for deep clones. +#[cfg(feature = "gecko")] +pub struct DeepCloneParams { + /// The new sheet we're cloning rules into. + pub reference_sheet: *const ::gecko_bindings::structs::ServoStyleSheet, +} + +/// Parameters needed for deep clones. +#[cfg(feature = "servo")] +pub struct DeepCloneParams; + + /// A trait to do a deep clone of a given CSS type. Gets a lock and a read /// guard, in order to be able to read and clone nested structures. pub trait DeepCloneWithLock : Sized { @@ -235,7 +247,8 @@ pub trait DeepCloneWithLock : Sized { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self; } diff --git a/components/style/stylesheet_set.rs b/components/style/stylesheet_set.rs index 8c66d51c3b0..07ef6fe24b2 100644 --- a/components/style/stylesheet_set.rs +++ b/components/style/stylesheet_set.rs @@ -8,36 +8,46 @@ use dom::TElement; use invalidation::stylesheets::StylesheetInvalidationSet; use shared_lock::SharedRwLockReadGuard; use std::slice; -use stylearc::Arc; -use stylesheets::Stylesheet; +use stylesheets::StylesheetInDocument; use stylist::Stylist; /// Entry for a StylesheetSet. We don't bother creating a constructor, because /// there's no sensible defaults for the member variables. -pub struct StylesheetSetEntry { - unique_id: u64, - sheet: Arc, +pub struct StylesheetSetEntry +where + S: StylesheetInDocument + PartialEq + 'static, +{ + sheet: S, } /// A iterator over the stylesheets of a list of entries in the StylesheetSet. #[derive(Clone)] -pub struct StylesheetIterator<'a>(slice::Iter<'a, StylesheetSetEntry>); +pub struct StylesheetIterator<'a, S>(slice::Iter<'a, StylesheetSetEntry>) +where + S: StylesheetInDocument + PartialEq + 'static; + +impl<'a, S> Iterator for StylesheetIterator<'a, S> +where + S: StylesheetInDocument + PartialEq + 'static, +{ + type Item = &'a S; -impl<'a> Iterator for StylesheetIterator<'a> { - type Item = &'a Arc; fn next(&mut self) -> Option { self.0.next().map(|entry| &entry.sheet) } } /// The set of stylesheets effective for a given document. -pub struct StylesheetSet { +pub struct StylesheetSet +where + S: StylesheetInDocument + PartialEq + 'static, +{ /// The actual list of all the stylesheets that apply to the given document, /// each stylesheet associated with a unique ID. /// /// This is only a list of top-level stylesheets, and as such it doesn't /// include recursive `@import` rules. - entries: Vec, + entries: Vec>, /// Whether the entries list above has changed since the last restyle. dirty: bool, @@ -49,7 +59,10 @@ pub struct StylesheetSet { invalidations: StylesheetInvalidationSet, } -impl StylesheetSet { +impl StylesheetSet +where + S: StylesheetInDocument + PartialEq + 'static, +{ /// Create a new empty StylesheetSet. pub fn new() -> Self { StylesheetSet { @@ -66,98 +79,72 @@ impl StylesheetSet { self.author_style_disabled } - fn remove_stylesheet_if_present(&mut self, unique_id: u64) { - self.entries.retain(|x| x.unique_id != unique_id); + fn remove_stylesheet_if_present(&mut self, sheet: &S) { + self.entries.retain(|entry| entry.sheet != *sheet); } /// Appends a new stylesheet to the current set. pub fn append_stylesheet( &mut self, stylist: &Stylist, - sheet: &Arc, - unique_id: u64, - guard: &SharedRwLockReadGuard) - { + sheet: S, + guard: &SharedRwLockReadGuard + ) { debug!("StylesheetSet::append_stylesheet"); - self.remove_stylesheet_if_present(unique_id); - self.entries.push(StylesheetSetEntry { - unique_id: unique_id, - sheet: sheet.clone(), - }); - self.dirty = true; + self.remove_stylesheet_if_present(&sheet); self.invalidations.collect_invalidations_for( stylist, - sheet, - guard) + &sheet, + guard + ); + self.dirty = true; + self.entries.push(StylesheetSetEntry { sheet }); } /// Prepend a new stylesheet to the current set. pub fn prepend_stylesheet( &mut self, stylist: &Stylist, - sheet: &Arc, - unique_id: u64, - guard: &SharedRwLockReadGuard) - { + sheet: S, + guard: &SharedRwLockReadGuard + ) { debug!("StylesheetSet::prepend_stylesheet"); - self.remove_stylesheet_if_present(unique_id); - self.entries.insert(0, StylesheetSetEntry { - unique_id: unique_id, - sheet: sheet.clone(), - }); - self.dirty = true; + self.remove_stylesheet_if_present(&sheet); self.invalidations.collect_invalidations_for( stylist, - sheet, - guard) + &sheet, + guard + ); + self.entries.insert(0, StylesheetSetEntry { sheet }); + self.dirty = true; } /// Insert a given stylesheet before another stylesheet in the document. pub fn insert_stylesheet_before( &mut self, stylist: &Stylist, - sheet: &Arc, - unique_id: u64, - before_unique_id: u64, + sheet: S, + before_sheet: S, guard: &SharedRwLockReadGuard) { debug!("StylesheetSet::insert_stylesheet_before"); - self.remove_stylesheet_if_present(unique_id); - let index = self.entries.iter().position(|x| { - x.unique_id == before_unique_id - }).expect("`before_unique_id` stylesheet not found"); - self.entries.insert(index, StylesheetSetEntry { - unique_id: unique_id, - sheet: sheet.clone(), - }); - self.dirty = true; + self.remove_stylesheet_if_present(&sheet); + let index = self.entries.iter().position(|entry| { + entry.sheet == before_sheet + }).expect("`before_sheet` stylesheet not found"); self.invalidations.collect_invalidations_for( stylist, - sheet, - guard) - } - - /// Update the sheet that matches the unique_id. - pub fn update_stylesheet( - &mut self, - sheet: &Arc, - unique_id: u64) - { - // Since this function doesn't set self.dirty, or call - // self.invalidations.collect_invalidations_for, it should - // only be called in the case where sheet is a clone of - // the sheet it is updating. - debug!("StylesheetSet::update_stylesheet"); - if let Some(entry) = self.entries.iter_mut().find( - |e| e.unique_id == unique_id) { - entry.sheet = sheet.clone(); - } + &sheet, + guard + ); + self.entries.insert(index, StylesheetSetEntry { sheet }); + self.dirty = true; } /// Remove a given stylesheet from the set. - pub fn remove_stylesheet(&mut self, unique_id: u64) { + pub fn remove_stylesheet(&mut self, sheet: S) { debug!("StylesheetSet::remove_stylesheet"); - self.remove_stylesheet_if_present(unique_id); + self.remove_stylesheet_if_present(&sheet); self.dirty = true; // FIXME(emilio): We can do better! self.invalidations.invalidate_fully(); @@ -181,10 +168,12 @@ impl StylesheetSet { /// Flush the current set, unmarking it as dirty, and returns an iterator /// over the new stylesheet list. - pub fn flush(&mut self, - document_element: Option) - -> StylesheetIterator - where E: TElement, + pub fn flush( + &mut self, + document_element: Option + ) -> StylesheetIterator + where + E: TElement, { debug!("StylesheetSet::flush"); debug_assert!(self.dirty); @@ -196,7 +185,7 @@ impl StylesheetSet { } /// Returns an iterator over the current list of stylesheets. - pub fn iter(&self) -> StylesheetIterator { + pub fn iter(&self) -> StylesheetIterator { StylesheetIterator(self.entries.iter()) } diff --git a/components/style/stylesheets/document_rule.rs b/components/style/stylesheets/document_rule.rs index a4ac747f2a0..f8388eb5dda 100644 --- a/components/style/stylesheets/document_rule.rs +++ b/components/style/stylesheets/document_rule.rs @@ -9,7 +9,7 @@ use cssparser::{Parser, Token, SourceLocation, BasicParseError}; use media_queries::Device; use parser::{Parse, ParserContext}; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::{ToCss, ParseError, StyleParseError}; use stylearc::Arc; @@ -47,11 +47,12 @@ impl DeepCloneWithLock for DocumentRule { &self, lock: &SharedRwLock, guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self { let rules = self.rules.read_with(guard); DocumentRule { condition: self.condition.clone(), - rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard))), + rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard, params))), source_location: self.source_location.clone(), } } diff --git a/components/style/stylesheets/import_rule.rs b/components/style/stylesheets/import_rule.rs index 96edfca2314..5f7812fd67e 100644 --- a/components/style/stylesheets/import_rule.rs +++ b/components/style/stylesheets/import_rule.rs @@ -7,13 +7,72 @@ //! [import]: https://drafts.csswg.org/css-cascade-3/#at-import use cssparser::SourceLocation; -use shared_lock::{SharedRwLockReadGuard, ToCssWithGuard}; +use media_queries::MediaList; +use shared_lock::{DeepCloneWithLock, DeepCloneParams, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::ToCss; -use stylearc::Arc; -use stylesheets::stylesheet::Stylesheet; +use stylesheets::{StylesheetContents, StylesheetInDocument}; use values::specified::url::SpecifiedUrl; +/// A sheet that is held from an import rule. +#[cfg(feature = "gecko")] +#[derive(Debug)] +pub struct ImportSheet(pub ::gecko::data::GeckoStyleSheet); + +#[cfg(feature = "gecko")] +impl DeepCloneWithLock for ImportSheet { + fn deep_clone_with_lock( + &self, + _lock: &SharedRwLock, + _guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, + ) -> Self { + use gecko::data::GeckoStyleSheet; + use gecko_bindings::bindings; + let clone = unsafe { + bindings::Gecko_StyleSheet_Clone( + self.0.raw() as *const _, + params.reference_sheet + ) + }; + ImportSheet(unsafe { GeckoStyleSheet::from_addrefed(clone) }) + } +} + +/// A sheet that is held from an import rule. +#[cfg(feature = "servo")] +#[derive(Debug)] +pub struct ImportSheet(pub ::stylearc::Arc<::stylesheets::Stylesheet>); + +impl StylesheetInDocument for ImportSheet { + /// Get the media associated with this stylesheet. + fn media<'a>(&'a self, guard: &'a SharedRwLockReadGuard) -> Option<&'a MediaList> { + self.0.media(guard) + } + + fn contents(&self, guard: &SharedRwLockReadGuard) -> &StylesheetContents { + self.0.contents(guard) + } + + fn enabled(&self) -> bool { + self.0.enabled() + } +} + +#[cfg(feature = "servo")] +impl DeepCloneWithLock for ImportSheet { + fn deep_clone_with_lock( + &self, + _lock: &SharedRwLock, + _guard: &SharedRwLockReadGuard, + _params: &DeepCloneParams, + ) -> Self { + use stylearc::Arc; + + ImportSheet(Arc::new((&*self.0).clone())) + } +} + /// The [`@import`][import] at-rule. /// /// [import]: https://drafts.csswg.org/css-cascade-3/#at-import @@ -26,18 +85,22 @@ pub struct ImportRule { /// /// It contains an empty list of rules and namespace set that is updated /// when it loads. - pub stylesheet: Arc, + pub stylesheet: ImportSheet, /// The line and column of the rule's source code. pub source_location: SourceLocation, } -impl Clone for ImportRule { - fn clone(&self) -> ImportRule { - let stylesheet: &Stylesheet = &*self.stylesheet; +impl DeepCloneWithLock for ImportRule { + fn deep_clone_with_lock( + &self, + lock: &SharedRwLock, + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, + ) -> Self { ImportRule { url: self.url.clone(), - stylesheet: Arc::new(stylesheet.clone()), + stylesheet: self.stylesheet.deep_clone_with_lock(lock, guard, params), source_location: self.source_location.clone(), } } @@ -49,11 +112,15 @@ impl ToCssWithGuard for ImportRule { { dest.write_str("@import ")?; self.url.to_css(dest)?; - let media = self.stylesheet.media.read_with(guard); - if !media.is_empty() { - dest.write_str(" ")?; - media.to_css(dest)?; - } + + match self.stylesheet.media(guard) { + Some(media) if !media.is_empty() => { + dest.write_str(" ")?; + media.to_css(dest)?; + } + _ => {}, + }; + dest.write_str(";") } } diff --git a/components/style/stylesheets/keyframes_rule.rs b/components/style/stylesheets/keyframes_rule.rs index 8e12dbca9a4..356b675575f 100644 --- a/components/style/stylesheets/keyframes_rule.rs +++ b/components/style/stylesheets/keyframes_rule.rs @@ -14,11 +14,11 @@ use properties::LonghandIdSet; use properties::animated_properties::AnimatableLonghand; use properties::longhands::transition_timing_function::single_value::SpecifiedValue as SpecifiedTimingFunction; use selectors::parser::SelectorParseError; -use shared_lock::{DeepCloneWithLock, SharedRwLock, SharedRwLockReadGuard, Locked, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, SharedRwLock, SharedRwLockReadGuard, Locked, ToCssWithGuard}; use std::fmt; use style_traits::{PARSING_MODE_DEFAULT, ToCss, ParseError, StyleParseError}; use stylearc::Arc; -use stylesheets::{CssRuleType, Stylesheet}; +use stylesheets::{CssRuleType, StylesheetContents}; use stylesheets::rule_parser::VendorPrefix; use values::KeyframesName; @@ -78,13 +78,17 @@ impl DeepCloneWithLock for KeyframesRule { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self { KeyframesRule { name: self.name.clone(), keyframes: self.keyframes.iter() - .map(|ref x| Arc::new(lock.wrap( - x.read_with(guard).deep_clone_with_lock(lock, guard)))) + .map(|x| { + Arc::new(lock.wrap( + x.read_with(guard).deep_clone_with_lock(lock, guard, params) + )) + }) .collect(), vendor_prefix: self.vendor_prefix.clone(), source_location: self.source_location.clone(), @@ -202,23 +206,26 @@ impl ToCssWithGuard for Keyframe { impl Keyframe { /// Parse a CSS keyframe. - pub fn parse<'i>(css: &'i str, parent_stylesheet: &Stylesheet) - -> Result>, ParseError<'i>> { - let url_data = parent_stylesheet.url_data.read(); + pub fn parse<'i>( + css: &'i str, + parent_stylesheet_contents: &StylesheetContents, + lock: &SharedRwLock, + ) -> Result>, ParseError<'i>> { + let url_data = parent_stylesheet_contents.url_data.read(); let error_reporter = NullReporter; - let context = ParserContext::new(parent_stylesheet.origin, + let context = ParserContext::new(parent_stylesheet_contents.origin, &url_data, &error_reporter, Some(CssRuleType::Keyframe), PARSING_MODE_DEFAULT, - parent_stylesheet.quirks_mode); + parent_stylesheet_contents.quirks_mode); let mut input = ParserInput::new(css); let mut input = Parser::new(&mut input); let mut declarations = SourcePropertyDeclaration::new(); let mut rule_parser = KeyframeListParser { context: &context, - shared_lock: &parent_stylesheet.shared_lock, + shared_lock: &lock, declarations: &mut declarations, }; parse_one_rule(&mut input, &mut rule_parser) @@ -230,7 +237,8 @@ impl DeepCloneWithLock for Keyframe { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + _params: &DeepCloneParams, ) -> Keyframe { Keyframe { selector: self.selector.clone(), diff --git a/components/style/stylesheets/loader.rs b/components/style/stylesheets/loader.rs index ff38ff3ed2a..3e90ad8b6a1 100644 --- a/components/style/stylesheets/loader.rs +++ b/components/style/stylesheets/loader.rs @@ -5,39 +5,25 @@ //! The stylesheet loader is the abstraction used to trigger network requests //! for `@import` rules. +use cssparser::SourceLocation; use media_queries::MediaList; -use shared_lock::Locked; +use parser::ParserContext; +use shared_lock::{Locked, SharedRwLock}; use stylearc::Arc; -use stylesheets::ImportRule; +use stylesheets::import_rule::ImportRule; +use values::specified::url::SpecifiedUrl; /// The stylesheet loader is the abstraction used to trigger network requests /// for `@import` rules. pub trait StylesheetLoader { - /// Request a stylesheet after parsing a given `@import` rule. - /// - /// The called code is responsible to update the `stylesheet` rules field - /// when the sheet is done loading. - /// - /// The convoluted signature allows impls to look at MediaList and - /// ImportRule before they’re locked, while keeping the trait object-safe. + /// Request a stylesheet after parsing a given `@import` rule, and return + /// the constructed `@import` rule. fn request_stylesheet( &self, + url: SpecifiedUrl, + location: SourceLocation, + context: &ParserContext, + lock: &SharedRwLock, media: Arc>, - make_import: &mut FnMut(Arc>) -> ImportRule, - make_arc: &mut FnMut(ImportRule) -> Arc>, ) -> Arc>; } - -/// A dummy loader that just creates the import rule with the empty stylesheet. -pub struct NoOpLoader; - -impl StylesheetLoader for NoOpLoader { - fn request_stylesheet( - &self, - media: Arc>, - make_import: &mut FnMut(Arc>) -> ImportRule, - make_arc: &mut FnMut(ImportRule) -> Arc>, - ) -> Arc> { - make_arc(make_import(media)) - } -} diff --git a/components/style/stylesheets/media_rule.rs b/components/style/stylesheets/media_rule.rs index 13938513d60..600d6a920d4 100644 --- a/components/style/stylesheets/media_rule.rs +++ b/components/style/stylesheets/media_rule.rs @@ -8,7 +8,7 @@ use cssparser::SourceLocation; use media_queries::MediaList; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::ToCss; use stylearc::Arc; @@ -47,13 +47,14 @@ impl DeepCloneWithLock for MediaRule { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self { let media_queries = self.media_queries.read_with(guard); let rules = self.rules.read_with(guard); MediaRule { media_queries: Arc::new(lock.wrap(media_queries.clone())), - rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard))), + rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard, params))), source_location: self.source_location.clone(), } } diff --git a/components/style/stylesheets/mod.rs b/components/style/stylesheets/mod.rs index e5e6aa521f9..33a4e2ab18c 100644 --- a/components/style/stylesheets/mod.rs +++ b/components/style/stylesheets/mod.rs @@ -7,7 +7,7 @@ mod counter_style_rule; mod document_rule; mod font_face_rule; -mod import_rule; +pub mod import_rule; pub mod keyframes_rule; mod loader; mod media_rule; @@ -25,7 +25,7 @@ pub mod viewport_rule; use cssparser::{parse_one_rule, Parser, ParserInput}; use error_reporting::NullReporter; use parser::ParserContext; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::PARSING_MODE_DEFAULT; use stylearc::Arc; @@ -43,7 +43,7 @@ pub use self::page_rule::PageRule; pub use self::rule_parser::{State, TopLevelRuleParser}; pub use self::rule_list::{CssRules, CssRulesHelpers}; pub use self::rules_iterator::{AllRules, EffectiveRules, NestedRuleIterationCondition, RulesIterator}; -pub use self::stylesheet::{Namespaces, Stylesheet, UserAgentStylesheets}; +pub use self::stylesheet::{Namespaces, Stylesheet, StylesheetContents, StylesheetInDocument, UserAgentStylesheets}; pub use self::style_rule::StyleRule; pub use self::supports_rule::SupportsRule; pub use self::viewport_rule::ViewportRule; @@ -221,32 +221,33 @@ impl CssRule { /// Input state is None for a nested rule pub fn parse( css: &str, - parent_stylesheet: &Stylesheet, + parent_stylesheet_contents: &StylesheetContents, + shared_lock: &SharedRwLock, state: Option, loader: Option<&StylesheetLoader> ) -> Result<(Self, State), SingleRuleParseError> { - let url_data = parent_stylesheet.url_data.read(); + let url_data = parent_stylesheet_contents.url_data.read(); let error_reporter = NullReporter; let context = ParserContext::new( - parent_stylesheet.origin, + parent_stylesheet_contents.origin, &url_data, &error_reporter, None, PARSING_MODE_DEFAULT, - parent_stylesheet.quirks_mode + parent_stylesheet_contents.quirks_mode, ); let mut input = ParserInput::new(css); let mut input = Parser::new(&mut input); - let mut guard = parent_stylesheet.namespaces.write(); + let mut guard = parent_stylesheet_contents.namespaces.write(); // nested rules are in the body state let state = state.unwrap_or(State::Body); let mut rule_parser = TopLevelRuleParser { - stylesheet_origin: parent_stylesheet.origin, + stylesheet_origin: parent_stylesheet_contents.origin, context: context, - shared_lock: &parent_stylesheet.shared_lock, + shared_lock: &shared_lock, loader: loader, state: state, namespaces: Some(&mut *guard), @@ -270,6 +271,7 @@ impl DeepCloneWithLock for CssRule { &self, lock: &SharedRwLock, guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> CssRule { match *self { CssRule::Namespace(ref arc) => { @@ -277,18 +279,19 @@ impl DeepCloneWithLock for CssRule { CssRule::Namespace(Arc::new(lock.wrap(rule.clone()))) }, CssRule::Import(ref arc) => { - let rule = arc.read_with(guard); - CssRule::Import(Arc::new(lock.wrap(rule.clone()))) + let rule = arc.read_with(guard) + .deep_clone_with_lock(lock, guard, params); + CssRule::Import(Arc::new(lock.wrap(rule))) }, CssRule::Style(ref arc) => { let rule = arc.read_with(guard); CssRule::Style(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, CssRule::Media(ref arc) => { let rule = arc.read_with(guard); CssRule::Media(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, CssRule::FontFace(ref arc) => { let rule = arc.read_with(guard); @@ -307,22 +310,22 @@ impl DeepCloneWithLock for CssRule { CssRule::Keyframes(ref arc) => { let rule = arc.read_with(guard); CssRule::Keyframes(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, CssRule::Supports(ref arc) => { let rule = arc.read_with(guard); CssRule::Supports(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, CssRule::Page(ref arc) => { let rule = arc.read_with(guard); CssRule::Page(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, CssRule::Document(ref arc) => { let rule = arc.read_with(guard); CssRule::Document(Arc::new( - lock.wrap(rule.deep_clone_with_lock(lock, guard)))) + lock.wrap(rule.deep_clone_with_lock(lock, guard, params)))) }, } } diff --git a/components/style/stylesheets/page_rule.rs b/components/style/stylesheets/page_rule.rs index 4ec3a5f6aaf..c29353b4e5b 100644 --- a/components/style/stylesheets/page_rule.rs +++ b/components/style/stylesheets/page_rule.rs @@ -8,7 +8,7 @@ use cssparser::SourceLocation; use properties::PropertyDeclarationBlock; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::ToCss; use stylearc::Arc; @@ -51,6 +51,7 @@ impl DeepCloneWithLock for PageRule { &self, lock: &SharedRwLock, guard: &SharedRwLockReadGuard, + _params: &DeepCloneParams, ) -> Self { PageRule { block: Arc::new(lock.wrap(self.block.read_with(&guard).clone())), diff --git a/components/style/stylesheets/rule_list.rs b/components/style/stylesheets/rule_list.rs index 7067760f44a..9b939ddf131 100644 --- a/components/style/stylesheets/rule_list.rs +++ b/components/style/stylesheets/rule_list.rs @@ -4,13 +4,13 @@ //! A list of CSS rules. -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard}; use stylearc::Arc; use stylesheets::{CssRule, RulesMutateError}; use stylesheets::loader::StylesheetLoader; use stylesheets::memory::{MallocSizeOfFn, MallocSizeOfWithGuard}; use stylesheets::rule_parser::State; -use stylesheets::stylesheet::Stylesheet; +use stylesheets::stylesheet::StylesheetContents; /// A list of CSS rules. #[derive(Debug)] @@ -27,11 +27,12 @@ impl DeepCloneWithLock for CssRules { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self { - CssRules( - self.0.iter().map(|ref x| x.deep_clone_with_lock(lock, guard)).collect() - ) + CssRules(self.0.iter().map(|x| { + x.deep_clone_with_lock(lock, guard, params) + }).collect()) } } @@ -101,7 +102,7 @@ pub trait CssRulesHelpers { fn insert_rule(&self, lock: &SharedRwLock, rule: &str, - parent_stylesheet: &Stylesheet, + parent_stylesheet_contents: &StylesheetContents, index: usize, nested: bool, loader: Option<&StylesheetLoader>) @@ -112,7 +113,7 @@ impl CssRulesHelpers for Arc> { fn insert_rule(&self, lock: &SharedRwLock, rule: &str, - parent_stylesheet: &Stylesheet, + parent_stylesheet_contents: &StylesheetContents, index: usize, nested: bool, loader: Option<&StylesheetLoader>) @@ -139,7 +140,13 @@ impl CssRulesHelpers for Arc> { // Step 3, 4 // XXXManishearth should we also store the namespace map? let (new_rule, new_state) = - CssRule::parse(&rule, parent_stylesheet, state, loader)?; + CssRule::parse( + &rule, + parent_stylesheet_contents, + lock, + state, + loader + )?; { let mut write_guard = lock.write(); diff --git a/components/style/stylesheets/rule_parser.rs b/components/style/stylesheets/rule_parser.rs index 55f49d24f98..b622ef1001a 100644 --- a/components/style/stylesheets/rule_parser.rs +++ b/components/style/stylesheets/rule_parser.rs @@ -11,7 +11,6 @@ use cssparser::{CompactCowStr, SourceLocation}; use error_reporting::ContextualParseError; use font_face::parse_font_face_block; use media_queries::{parse_media_query_list, MediaList}; -use parking_lot::RwLock; use parser::{Parse, ParserContext, log_css_error}; use properties::parse_property_declaration_list; use selector_parser::{SelectorImpl, SelectorParser}; @@ -19,17 +18,15 @@ use selectors::SelectorList; use selectors::parser::SelectorParseError; use shared_lock::{Locked, SharedRwLock}; use std::borrow::Cow; -use std::sync::atomic::AtomicBool; use str::starts_with_ignore_ascii_case; use style_traits::{StyleParseError, ParseError}; use stylearc::Arc; use stylesheets::{CssRule, CssRules, CssRuleType, Origin, StylesheetLoader}; -use stylesheets::{DocumentRule, ImportRule, KeyframesRule, MediaRule, NamespaceRule, PageRule}; +use stylesheets::{DocumentRule, KeyframesRule, MediaRule, NamespaceRule, PageRule}; use stylesheets::{StyleRule, SupportsRule, ViewportRule}; use stylesheets::document_rule::DocumentCondition; use stylesheets::keyframes_rule::parse_keyframe_list; -use stylesheets::loader::NoOpLoader; -use stylesheets::stylesheet::{Namespaces, Stylesheet}; +use stylesheets::stylesheet::Namespaces; use stylesheets::supports_rule::SupportsCondition; use stylesheets::viewport_rule; use values::CustomIdent; @@ -165,35 +162,18 @@ impl<'a, 'i> AtRuleParser<'i> for TopLevelRuleParser<'a> { let media = parse_media_query_list(&self.context, input); let media = Arc::new(self.shared_lock.wrap(media)); - let noop_loader = NoOpLoader; - let loader = if !specified_url.is_invalid() { - self.loader.expect("Expected a stylesheet loader for @import") - } else { - &noop_loader - }; + let loader = + self.loader.expect("Expected a stylesheet loader for @import"); - let mut specified_url = Some(specified_url); - let arc = loader.request_stylesheet(media, &mut |media| { - ImportRule { - url: specified_url.take().unwrap(), - stylesheet: Arc::new(Stylesheet { - rules: CssRules::new(Vec::new(), self.shared_lock), - media: media, - shared_lock: self.shared_lock.clone(), - origin: self.context.stylesheet_origin, - url_data: RwLock::new(self.context.url_data.clone()), - namespaces: RwLock::new(Namespaces::default()), - dirty_on_viewport_size_change: AtomicBool::new(false), - disabled: AtomicBool::new(false), - quirks_mode: self.context.quirks_mode, - }), - source_location: location, - } - }, &mut |import_rule| { - Arc::new(self.shared_lock.wrap(import_rule)) - }); + let import_rule = loader.request_stylesheet( + specified_url, + location, + &self.context, + &self.shared_lock, + media, + ); - return Ok(AtRuleType::WithoutBlock(CssRule::Import(arc))) + return Ok(AtRuleType::WithoutBlock(CssRule::Import(import_rule))) }, "namespace" => { if self.state > State::Namespaces { diff --git a/components/style/stylesheets/rules_iterator.rs b/components/style/stylesheets/rules_iterator.rs index 05dd2e71676..cb8f83abb7d 100644 --- a/components/style/stylesheets/rules_iterator.rs +++ b/components/style/stylesheets/rules_iterator.rs @@ -10,6 +10,7 @@ use shared_lock::SharedRwLockReadGuard; use smallvec::SmallVec; use std::slice; use stylesheets::{CssRule, CssRules, DocumentRule, ImportRule, MediaRule, SupportsRule}; +use stylesheets::StylesheetInDocument; /// An iterator over a list of rules. pub struct RulesIterator<'a, 'b, C> @@ -96,7 +97,9 @@ impl<'a, 'b, C> Iterator for RulesIterator<'a, 'b, C> import_rule) { continue; } - import_rule.stylesheet.rules.read_with(self.guard).0.iter() + import_rule + .stylesheet.contents(self.guard).rules + .read_with(self.guard).0.iter() } CssRule::Document(ref doc_rule) => { let doc_rule = doc_rule.read_with(self.guard); @@ -182,11 +185,11 @@ impl NestedRuleIterationCondition for EffectiveRules { fn process_import( guard: &SharedRwLockReadGuard, device: &Device, - quirks_mode: QuirksMode, + _quirks_mode: QuirksMode, rule: &ImportRule) -> bool { - rule.stylesheet.media.read_with(guard).evaluate(device, quirks_mode) + rule.stylesheet.is_effective_for_device(device, guard) } fn process_media( diff --git a/components/style/stylesheets/style_rule.rs b/components/style/stylesheets/style_rule.rs index c8a3da00063..5f647321786 100644 --- a/components/style/stylesheets/style_rule.rs +++ b/components/style/stylesheets/style_rule.rs @@ -8,7 +8,7 @@ use cssparser::SourceLocation; use properties::PropertyDeclarationBlock; use selector_parser::SelectorImpl; use selectors::SelectorList; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::ToCss; use stylearc::Arc; @@ -31,6 +31,7 @@ impl DeepCloneWithLock for StyleRule { &self, lock: &SharedRwLock, guard: &SharedRwLockReadGuard, + _params: &DeepCloneParams, ) -> StyleRule { StyleRule { selectors: self.selectors.clone(), diff --git a/components/style/stylesheets/stylesheet.rs b/components/style/stylesheets/stylesheet.rs index 477c35f8e64..b2595faa8d3 100644 --- a/components/style/stylesheets/stylesheet.rs +++ b/components/style/stylesheets/stylesheet.rs @@ -10,7 +10,7 @@ use fnv::FnvHashMap; use media_queries::{MediaList, Device}; use parking_lot::RwLock; use parser::{ParserContext, log_css_error}; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard}; use std::mem; use std::sync::atomic::{AtomicBool, Ordering}; use style_traits::PARSING_MODE_DEFAULT; @@ -42,28 +42,232 @@ pub struct Namespaces { pub prefixes: FnvHashMap, } -/// The structure servo uses to represent a stylesheet. +/// The contents of a given stylesheet. This effectively maps to a +/// StyleSheetInner in Gecko. #[derive(Debug)] -pub struct Stylesheet { +pub struct StylesheetContents { /// List of rules in the order they were found (important for /// cascading order) pub rules: Arc>, - /// List of media associated with the Stylesheet. - pub media: Arc>, /// The origin of this stylesheet. pub origin: Origin, /// The url data this stylesheet should use. pub url_data: RwLock, - /// The lock used for objects inside this stylesheet - pub shared_lock: SharedRwLock, /// The namespaces that apply to this stylesheet. pub namespaces: RwLock, - /// Whether this stylesheet would be dirty when the viewport size changes. - pub dirty_on_viewport_size_change: AtomicBool, - /// Whether this stylesheet should be disabled. - pub disabled: AtomicBool, /// The quirks mode of this stylesheet. pub quirks_mode: QuirksMode, + /// Whether this stylesheet would be dirty when the viewport size changes. + pub dirty_on_viewport_size_change: AtomicBool, +} + +impl StylesheetContents { + /// Parse a given CSS string, with a given url-data, origin, and + /// quirks mode. + pub fn from_str( + css: &str, + url_data: UrlExtraData, + origin: Origin, + shared_lock: &SharedRwLock, + stylesheet_loader: Option<&StylesheetLoader>, + error_reporter: &ParseErrorReporter, + quirks_mode: QuirksMode, + line_number_offset: u64 + ) -> Self { + let namespaces = RwLock::new(Namespaces::default()); + let (rules, dirty_on_viewport_size_change) = Stylesheet::parse_rules( + css, + &url_data, + origin, + &mut *namespaces.write(), + &shared_lock, + stylesheet_loader, + error_reporter, + quirks_mode, + line_number_offset, + ); + + Self { + rules: CssRules::new(rules, &shared_lock), + origin: origin, + url_data: RwLock::new(url_data), + namespaces: namespaces, + dirty_on_viewport_size_change: AtomicBool::new(dirty_on_viewport_size_change), + quirks_mode: quirks_mode, + } + } + + /// Return an iterator using the condition `C`. + #[inline] + pub fn iter_rules<'a, 'b, C>( + &'a self, + device: &'a Device, + guard: &'a SharedRwLockReadGuard<'b> + ) -> RulesIterator<'a, 'b, C> + where + C: NestedRuleIterationCondition, + { + RulesIterator::new( + device, + self.quirks_mode, + guard, + &self.rules.read_with(guard) + ) + } +} + +impl DeepCloneWithLock for StylesheetContents { + fn deep_clone_with_lock( + &self, + lock: &SharedRwLock, + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, + ) -> Self { + // Make a deep clone of the rules, using the new lock. + let rules = + self.rules.read_with(guard) + .deep_clone_with_lock(lock, guard, params); + + let dirty_on_viewport_size_change = + AtomicBool::new(self.dirty_on_viewport_size_change.load(Ordering::Relaxed)); + + Self { + rules: Arc::new(lock.wrap(rules)), + dirty_on_viewport_size_change, + quirks_mode: self.quirks_mode, + origin: self.origin, + url_data: RwLock::new((*self.url_data.read()).clone()), + namespaces: RwLock::new((*self.namespaces.read()).clone()), + } + } +} + +impl MallocSizeOfWithGuard for StylesheetContents { + fn malloc_size_of_children( + &self, + guard: &SharedRwLockReadGuard, + malloc_size_of: MallocSizeOfFn + ) -> usize { + // Measurement of other fields may be added later. + self.rules.read_with(guard).malloc_size_of_children(guard, malloc_size_of) + } +} + +/// The structure servo uses to represent a stylesheet. +#[derive(Debug)] +pub struct Stylesheet { + /// The contents of this stylesheet. + pub contents: StylesheetContents, + /// The lock used for objects inside this stylesheet + pub shared_lock: SharedRwLock, + /// List of media associated with the Stylesheet. + pub media: Arc>, + /// Whether this stylesheet should be disabled. + pub disabled: AtomicBool, +} + +macro_rules! rule_filter { + ($( $method: ident($variant:ident => $rule_type: ident), )+) => { + $( + #[allow(missing_docs)] + fn $method(&self, device: &Device, guard: &SharedRwLockReadGuard, mut f: F) + where F: FnMut(&::stylesheets::$rule_type), + { + use stylesheets::CssRule; + + for rule in self.effective_rules(device, guard) { + if let CssRule::$variant(ref lock) = *rule { + let rule = lock.read_with(guard); + f(&rule) + } + } + } + )+ + } +} + +/// A trait to represent a given stylesheet in a document. +pub trait StylesheetInDocument { + /// Get the contents of this stylesheet. + fn contents(&self, guard: &SharedRwLockReadGuard) -> &StylesheetContents; + + /// Get the stylesheet origin. + fn origin(&self, guard: &SharedRwLockReadGuard) -> Origin { + self.contents(guard).origin + } + + /// Get the stylesheet quirks mode. + fn quirks_mode(&self, guard: &SharedRwLockReadGuard) -> QuirksMode { + self.contents(guard).quirks_mode + } + + /// Get the media associated with this stylesheet. + fn media<'a>(&'a self, guard: &'a SharedRwLockReadGuard) -> Option<&'a MediaList>; + + /// Returns whether the style-sheet applies for the current device. + fn is_effective_for_device( + &self, + device: &Device, + guard: &SharedRwLockReadGuard + ) -> bool { + match self.media(guard) { + Some(medialist) => medialist.evaluate(device, self.quirks_mode(guard)), + None => true, + } + } + + /// Get whether this stylesheet is enabled. + fn enabled(&self) -> bool; + + /// Return an iterator using the condition `C`. + #[inline] + fn iter_rules<'a, 'b, C>( + &'a self, + device: &'a Device, + guard: &'a SharedRwLockReadGuard<'b> + ) -> RulesIterator<'a, 'b, C> + where + C: NestedRuleIterationCondition, + { + self.contents(guard).iter_rules(device, guard) + } + + /// Return an iterator over the effective rules within the style-sheet, as + /// according to the supplied `Device`. + #[inline] + fn effective_rules<'a, 'b>( + &'a self, + device: &'a Device, + guard: &'a SharedRwLockReadGuard<'b> + ) -> EffectiveRulesIterator<'a, 'b> { + self.iter_rules::<'a, 'b, EffectiveRules>(device, guard) + } + + rule_filter! { + effective_style_rules(Style => StyleRule), + effective_media_rules(Media => MediaRule), + effective_font_face_rules(FontFace => FontFaceRule), + effective_counter_style_rules(CounterStyle => CounterStyleRule), + effective_viewport_rules(Viewport => ViewportRule), + effective_keyframes_rules(Keyframes => KeyframesRule), + effective_supports_rules(Supports => SupportsRule), + effective_page_rules(Page => PageRule), + effective_document_rules(Document => DocumentRule), + } +} + +impl StylesheetInDocument for Stylesheet { + fn contents(&self, _: &SharedRwLockReadGuard) -> &StylesheetContents { + &self.contents + } + + fn media<'a>(&'a self, guard: &'a SharedRwLockReadGuard) -> Option<&'a MediaList> { + Some(self.media.read_with(guard)) + } + + fn enabled(&self) -> bool { + !self.disabled() + } } impl Stylesheet { @@ -79,23 +283,26 @@ impl Stylesheet { Stylesheet::parse_rules( css, &url_data, - existing.origin, + existing.contents.origin, &mut *namespaces.write(), &existing.shared_lock, stylesheet_loader, error_reporter, - existing.quirks_mode, + existing.contents.quirks_mode, line_number_offset ); - *existing.url_data.write() = url_data; - mem::swap(&mut *existing.namespaces.write(), &mut *namespaces.write()); - existing.dirty_on_viewport_size_change + *existing.contents.url_data.write() = url_data; + mem::swap( + &mut *existing.contents.namespaces.write(), + &mut *namespaces.write() + ); + existing.contents.dirty_on_viewport_size_change .store(dirty_on_viewport_size_change, Ordering::Release); // Acquire the lock *after* parsing, to minimize the exclusive section. let mut guard = existing.shared_lock.write(); - *existing.rules.write_with(&mut guard) = CssRules(rules); + *existing.contents.rules.write_with(&mut guard) = CssRules(rules); } fn parse_rules( @@ -169,35 +376,28 @@ impl Stylesheet { quirks_mode: QuirksMode, line_number_offset: u64) -> Stylesheet { - let namespaces = RwLock::new(Namespaces::default()); - let (rules, dirty_on_viewport_size_change) = Stylesheet::parse_rules( + let contents = StylesheetContents::from_str( css, - &url_data, + url_data, origin, - &mut *namespaces.write(), &shared_lock, stylesheet_loader, error_reporter, quirks_mode, - line_number_offset, + line_number_offset ); Stylesheet { - origin: origin, - url_data: RwLock::new(url_data), - namespaces: namespaces, - rules: CssRules::new(rules, &shared_lock), - media: media, - shared_lock: shared_lock, - dirty_on_viewport_size_change: AtomicBool::new(dirty_on_viewport_size_change), + contents, + shared_lock, + media, disabled: AtomicBool::new(false), - quirks_mode: quirks_mode, } } /// Whether this stylesheet can be dirty on viewport size change. pub fn dirty_on_viewport_size_change(&self) -> bool { - self.dirty_on_viewport_size_change.load(Ordering::SeqCst) + self.contents.dirty_on_viewport_size_change.load(Ordering::SeqCst) } /// When CSSOM inserts a rule or declaration into this stylesheet, it needs to call this method @@ -212,43 +412,10 @@ impl Stylesheet { /// Instead, we conservatively assume there might be some. /// Restyling will some some more work than necessary, but give correct results. pub fn inserted_has_viewport_percentages(&self, has_viewport_percentages: bool) { - self.dirty_on_viewport_size_change.fetch_or(has_viewport_percentages, Ordering::SeqCst); - } - - /// Returns whether the style-sheet applies for the current device depending - /// on the associated MediaList. - /// - /// Always true if no associated MediaList exists. - pub fn is_effective_for_device(&self, device: &Device, guard: &SharedRwLockReadGuard) -> bool { - self.media.read_with(guard).evaluate(device, self.quirks_mode) - } - - /// Return an iterator over the effective rules within the style-sheet, as - /// according to the supplied `Device`. - #[inline] - pub fn effective_rules<'a, 'b>( - &'a self, - device: &'a Device, - guard: &'a SharedRwLockReadGuard<'b>) - -> EffectiveRulesIterator<'a, 'b> - { - self.iter_rules::<'a, 'b, EffectiveRules>(device, guard) - } - - /// Return an iterator using the condition `C`. - #[inline] - pub fn iter_rules<'a, 'b, C>( - &'a self, - device: &'a Device, - guard: &'a SharedRwLockReadGuard<'b>) - -> RulesIterator<'a, 'b, C> - where C: NestedRuleIterationCondition, - { - RulesIterator::new( - device, - self.quirks_mode, - guard, - &self.rules.read_with(guard)) + self.contents.dirty_on_viewport_size_change.fetch_or( + has_viewport_percentages, + Ordering::SeqCst + ); } /// Returns whether the stylesheet has been explicitly disabled through the @@ -269,76 +436,28 @@ impl Stylesheet { } } +#[cfg(feature = "servo")] impl Clone for Stylesheet { - fn clone(&self) -> Stylesheet { + fn clone(&self) -> Self { // Create a new lock for our clone. let lock = self.shared_lock.clone(); let guard = self.shared_lock.read(); - // Make a deep clone of the rules, using the new lock. - let rules = self.rules.read_with(&guard); - let cloned_rules = rules.deep_clone_with_lock(&lock, &guard); - // Make a deep clone of the media, using the new lock. - let media = self.media.read_with(&guard); - let cloned_media = media.clone(); + let media = self.media.read_with(&guard).clone(); + let media = Arc::new(lock.wrap(media)); + let contents = self.contents.deep_clone_with_lock( + &lock, + &guard, + &DeepCloneParams + ); Stylesheet { - rules: Arc::new(lock.wrap(cloned_rules)), - media: Arc::new(lock.wrap(cloned_media)), - origin: self.origin, - url_data: RwLock::new((*self.url_data.read()).clone()), + contents, + media: media, shared_lock: lock, - namespaces: RwLock::new((*self.namespaces.read()).clone()), - dirty_on_viewport_size_change: AtomicBool::new( - self.dirty_on_viewport_size_change.load(Ordering::SeqCst)), disabled: AtomicBool::new(self.disabled.load(Ordering::SeqCst)), - quirks_mode: self.quirks_mode, } } } -impl MallocSizeOfWithGuard for Stylesheet { - fn malloc_size_of_children( - &self, - guard: &SharedRwLockReadGuard, - malloc_size_of: MallocSizeOfFn - ) -> usize { - // Measurement of other fields may be added later. - self.rules.read_with(guard).malloc_size_of_children(guard, malloc_size_of) - } -} - -macro_rules! rule_filter { - ($( $method: ident($variant:ident => $rule_type: ident), )+) => { - impl Stylesheet { - $( - #[allow(missing_docs)] - pub fn $method(&self, device: &Device, guard: &SharedRwLockReadGuard, mut f: F) - where F: FnMut(&::stylesheets::$rule_type), - { - use stylesheets::CssRule; - - for rule in self.effective_rules(device, guard) { - if let CssRule::$variant(ref lock) = *rule { - let rule = lock.read_with(guard); - f(&rule) - } - } - } - )+ - } - } -} - -rule_filter! { - effective_style_rules(Style => StyleRule), - effective_media_rules(Media => MediaRule), - effective_font_face_rules(FontFace => FontFaceRule), - effective_counter_style_rules(CounterStyle => CounterStyleRule), - effective_viewport_rules(Viewport => ViewportRule), - effective_keyframes_rules(Keyframes => KeyframesRule), - effective_supports_rules(Supports => SupportsRule), - effective_page_rules(Page => PageRule), - effective_document_rules(Document => DocumentRule), -} diff --git a/components/style/stylesheets/supports_rule.rs b/components/style/stylesheets/supports_rule.rs index 1d9d52055ce..bfc497d6d90 100644 --- a/components/style/stylesheets/supports_rule.rs +++ b/components/style/stylesheets/supports_rule.rs @@ -9,7 +9,7 @@ use cssparser::{Delimiter, parse_important, Parser, SourceLocation, Token}; use parser::ParserContext; use properties::{PropertyId, PropertyDeclaration, SourcePropertyDeclaration}; use selectors::parser::SelectorParseError; -use shared_lock::{DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; +use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard}; use std::fmt; use style_traits::{ToCss, ParseError, StyleParseError}; use stylearc::Arc; @@ -48,12 +48,13 @@ impl DeepCloneWithLock for SupportsRule { fn deep_clone_with_lock( &self, lock: &SharedRwLock, - guard: &SharedRwLockReadGuard + guard: &SharedRwLockReadGuard, + params: &DeepCloneParams, ) -> Self { let rules = self.rules.read_with(guard); SupportsRule { condition: self.condition.clone(), - rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard))), + rules: Arc::new(lock.wrap(rules.deep_clone_with_lock(lock, guard, params))), enabled: self.enabled, source_location: self.source_location.clone(), } diff --git a/components/style/stylesheets/viewport_rule.rs b/components/style/stylesheets/viewport_rule.rs index ca95245a73d..e2d826228a5 100644 --- a/components/style/stylesheets/viewport_rule.rs +++ b/components/style/stylesheets/viewport_rule.rs @@ -26,8 +26,7 @@ use std::iter::Enumerate; use std::str::Chars; use style_traits::{PinchZoomFactor, ToCss, ParseError, StyleParseError}; use style_traits::viewport::{Orientation, UserZoom, ViewportConstraints, Zoom}; -use stylearc::Arc; -use stylesheets::{Stylesheet, Origin}; +use stylesheets::{StylesheetInDocument, Origin}; use values::computed::{Context, ToComputedValue}; use values::specified::{NoCalcLength, LengthOrPercentageOrAuto, ViewportPercentageLength}; @@ -563,11 +562,14 @@ impl Cascade { } } - pub fn from_stylesheets<'a, I>(stylesheets: I, - guard: &SharedRwLockReadGuard, - device: &Device) - -> Self - where I: Iterator>, + pub fn from_stylesheets<'a, I, S>( + stylesheets: I, + guard: &SharedRwLockReadGuard, + device: &Device + ) -> Self + where + I: Iterator, + S: StylesheetInDocument + 'static, { let mut cascade = Self::new(); for stylesheet in stylesheets { diff --git a/components/style/stylist.rs b/components/style/stylist.rs index 1eb4965e3e9..367570aa4ce 100644 --- a/components/style/stylist.rs +++ b/components/style/stylist.rs @@ -15,7 +15,7 @@ use font_metrics::FontMetricsProvider; #[cfg(feature = "gecko")] use gecko_bindings::structs::{nsIAtom, StyleRuleInclusion}; use invalidation::element::invalidation_map::InvalidationMap; -use invalidation::media_queries::EffectiveMediaQueryResults; +use invalidation::media_queries::{EffectiveMediaQueryResults, ToMediaListKey}; use matching::CascadeVisitedMode; use media_queries::Device; use properties::{self, CascadeFlags, ComputedValues}; @@ -43,7 +43,7 @@ use stylearc::Arc; #[cfg(feature = "gecko")] use stylesheets::{CounterStyleRule, FontFaceRule}; use stylesheets::{CssRule, StyleRule}; -use stylesheets::{Stylesheet, Origin, UserAgentStylesheets}; +use stylesheets::{StylesheetInDocument, Origin, UserAgentStylesheets}; use stylesheets::keyframes_rule::KeyframesAnimation; use stylesheets::viewport_rule::{self, MaybeNew, ViewportRule}; use thread_state; @@ -342,14 +342,18 @@ impl Stylist { /// This method resets all the style data each time the stylesheets change /// (which is indicated by the `stylesheets_changed` parameter), or the /// device is dirty, which means we need to re-evaluate media queries. - pub fn rebuild<'a, 'b, I>(&mut self, - doc_stylesheets: I, - guards: &StylesheetGuards, - ua_stylesheets: Option<&UserAgentStylesheets>, - stylesheets_changed: bool, - author_style_disabled: bool, - extra_data: &mut ExtraStyleData<'a>) -> bool - where I: Iterator> + Clone, + pub fn rebuild<'a, 'b, I, S>( + &mut self, + doc_stylesheets: I, + guards: &StylesheetGuards, + ua_stylesheets: Option<&UserAgentStylesheets>, + stylesheets_changed: bool, + author_style_disabled: bool, + extra_data: &mut ExtraStyleData<'a> + ) -> bool + where + I: Iterator + Clone, + S: StylesheetInDocument + ToMediaListKey + 'static, { debug_assert!(!self.is_cleared || self.is_device_dirty); @@ -398,7 +402,7 @@ impl Stylist { if let Some(ua_stylesheets) = ua_stylesheets { for stylesheet in &ua_stylesheets.user_or_user_agent_stylesheets { - self.add_stylesheet(&stylesheet, guards.ua_or_user, extra_data); + self.add_stylesheet(stylesheet, guards.ua_or_user, extra_data); } if self.quirks_mode != QuirksMode::NoQuirks { @@ -409,10 +413,10 @@ impl Stylist { // Only use author stylesheets if author styles are enabled. let sheets_to_add = doc_stylesheets.filter(|s| { - !author_style_disabled || s.origin != Origin::Author + !author_style_disabled || s.origin(guards.author) != Origin::Author }); - for ref stylesheet in sheets_to_add { + for stylesheet in sheets_to_add { self.add_stylesheet(stylesheet, guards.author, extra_data); } @@ -429,14 +433,18 @@ impl Stylist { /// clear the stylist and then rebuild it. Chances are, you want to use /// either clear() or rebuild(), with the latter done lazily, instead. - pub fn update<'a, 'b, I>(&mut self, - doc_stylesheets: I, - guards: &StylesheetGuards, - ua_stylesheets: Option<&UserAgentStylesheets>, - stylesheets_changed: bool, - author_style_disabled: bool, - extra_data: &mut ExtraStyleData<'a>) -> bool - where I: Iterator> + Clone, + pub fn update<'a, 'b, I, S>( + &mut self, + doc_stylesheets: I, + guards: &StylesheetGuards, + ua_stylesheets: Option<&UserAgentStylesheets>, + stylesheets_changed: bool, + author_style_disabled: bool, + extra_data: &mut ExtraStyleData<'a> + ) -> bool + where + I: Iterator + Clone, + S: StylesheetInDocument + ToMediaListKey + 'static, { debug_assert!(!self.is_cleared || self.is_device_dirty); @@ -450,16 +458,23 @@ impl Stylist { author_style_disabled, extra_data) } - fn add_stylesheet<'a>(&mut self, - stylesheet: &Stylesheet, - guard: &SharedRwLockReadGuard, - _extra_data: &mut ExtraStyleData<'a>) { - if stylesheet.disabled() || !stylesheet.is_effective_for_device(&self.device, guard) { + fn add_stylesheet<'a, S>( + &mut self, + stylesheet: &S, + guard: &SharedRwLockReadGuard, + _extra_data: &mut ExtraStyleData<'a> + ) + where + S: StylesheetInDocument + ToMediaListKey + 'static, + { + if !stylesheet.enabled() || + !stylesheet.is_effective_for_device(&self.device, guard) { return; } self.effective_media_query_results.saw_effective(stylesheet); + let origin = stylesheet.origin(guard); for rule in stylesheet.effective_rules(&self.device, guard) { match *rule { CssRule::Style(ref locked) => { @@ -472,9 +487,9 @@ impl Stylist { self.pseudos_map .entry(pseudo.canonical()) .or_insert_with(PerPseudoElementSelectorMap::new) - .borrow_for_origin(&stylesheet.origin) + .borrow_for_origin(&origin) } else { - self.element_map.borrow_for_origin(&stylesheet.origin) + self.element_map.borrow_for_origin(&origin) }; map.insert( @@ -529,7 +544,7 @@ impl Stylist { } #[cfg(feature = "gecko")] CssRule::FontFace(ref rule) => { - _extra_data.add_font_face(&rule, stylesheet.origin); + _extra_data.add_font_face(&rule, origin); } #[cfg(feature = "gecko")] CssRule::CounterStyle(ref rule) => { @@ -909,9 +924,13 @@ impl Stylist { pub fn set_device(&mut self, mut device: Device, guard: &SharedRwLockReadGuard, - stylesheets: &[Arc]) { + stylesheets: &[Arc<::stylesheets::Stylesheet>]) { let cascaded_rule = ViewportRule { - declarations: viewport_rule::Cascade::from_stylesheets(stylesheets.iter(), guard, &device).finish(), + declarations: viewport_rule::Cascade::from_stylesheets( + stylesheets.iter().map(|s| &**s), + guard, + &device + ).finish(), }; self.viewport_constraints = @@ -923,7 +942,7 @@ impl Stylist { self.device = device; let features_changed = self.media_features_change_changed_style( - stylesheets.iter(), + stylesheets.iter().map(|s| &**s), guard ); self.is_device_dirty |= features_changed; @@ -931,12 +950,14 @@ impl Stylist { /// Returns whether, given a media feature change, any previously-applicable /// style has become non-applicable, or vice-versa. - pub fn media_features_change_changed_style<'a, I>( + pub fn media_features_change_changed_style<'a, I, S>( &self, stylesheets: I, guard: &SharedRwLockReadGuard, ) -> bool - where I: Iterator> + where + I: Iterator, + S: StylesheetInDocument + ToMediaListKey + 'static, { use invalidation::media_queries::PotentiallyEffectiveMediaRules; @@ -944,11 +965,10 @@ impl Stylist { for stylesheet in stylesheets { let effective_now = - stylesheet.media.read_with(guard) - .evaluate(&self.device, self.quirks_mode); + stylesheet.is_effective_for_device(&self.device, guard); let effective_then = - self.effective_media_query_results.was_effective(&**stylesheet); + self.effective_media_query_results.was_effective(stylesheet); if effective_now != effective_then { debug!(" > Stylesheet changed -> {}, {}", @@ -982,9 +1002,9 @@ impl Stylist { } CssRule::Import(ref lock) => { let import_rule = lock.read_with(guard); - let mq = import_rule.stylesheet.media.read_with(guard); let effective_now = - mq.evaluate(&self.device, self.quirks_mode); + import_rule.stylesheet + .is_effective_for_device(&self.device, guard); let effective_then = self.effective_media_query_results.was_effective(import_rule); if effective_now != effective_then { diff --git a/ports/geckolib/glue.rs b/ports/geckolib/glue.rs index 2fe6f9d806e..4f47df2ebc0 100644 --- a/ports/geckolib/glue.rs +++ b/ports/geckolib/glue.rs @@ -18,7 +18,7 @@ use style::dom::{ShowSubtreeData, TElement, TNode}; use style::element_state::ElementState; use style::error_reporting::RustLogReporter; use style::font_metrics::{FontMetricsProvider, get_metrics_provider_for_product}; -use style::gecko::data::{PerDocumentStyleData, PerDocumentStyleDataImpl}; +use style::gecko::data::{GeckoStyleSheet, PerDocumentStyleData, PerDocumentStyleDataImpl}; use style::gecko::global_style_data::{GLOBAL_STYLE_DATA, GlobalStyleData, STYLE_THREAD_POOL}; use style::gecko::restyle_damage::GeckoRestyleDamage; use style::gecko::selector_parser::PseudoElement; @@ -32,13 +32,13 @@ use style::gecko_bindings::bindings::{RawServoDocumentRule, RawServoDocumentRule use style::gecko_bindings::bindings::{RawServoImportRule, RawServoImportRuleBorrowed}; use style::gecko_bindings::bindings::{RawServoKeyframe, RawServoKeyframeBorrowed, RawServoKeyframeStrong}; use style::gecko_bindings::bindings::{RawServoKeyframesRule, RawServoKeyframesRuleBorrowed}; -use style::gecko_bindings::bindings::{RawServoMediaList, RawServoMediaListBorrowed, RawServoMediaListStrong}; +use style::gecko_bindings::bindings::{RawServoMediaListBorrowed, RawServoMediaListStrong}; use style::gecko_bindings::bindings::{RawServoMediaRule, RawServoMediaRuleBorrowed}; use style::gecko_bindings::bindings::{RawServoNamespaceRule, RawServoNamespaceRuleBorrowed}; use style::gecko_bindings::bindings::{RawServoPageRule, RawServoPageRuleBorrowed}; use style::gecko_bindings::bindings::{RawServoStyleSetBorrowed, RawServoStyleSetOwned}; -use style::gecko_bindings::bindings::{RawServoStyleSheetBorrowed, ServoComputedValuesBorrowed}; -use style::gecko_bindings::bindings::{RawServoStyleSheetStrong, ServoComputedValuesStrong}; +use style::gecko_bindings::bindings::{RawServoStyleSheetContentsBorrowed, ServoComputedValuesBorrowed}; +use style::gecko_bindings::bindings::{RawServoStyleSheetContentsStrong, ServoComputedValuesStrong}; use style::gecko_bindings::bindings::{RawServoSupportsRule, RawServoSupportsRuleBorrowed}; use style::gecko_bindings::bindings::{ServoCssRulesBorrowed, ServoCssRulesStrong}; use style::gecko_bindings::bindings::{nsACString, nsAString, nsCSSPropertyIDSetBorrowedMut}; @@ -59,14 +59,12 @@ use style::gecko_bindings::bindings::RawServoAnimationValueBorrowed; use style::gecko_bindings::bindings::RawServoAnimationValueMapBorrowedMut; use style::gecko_bindings::bindings::RawServoAnimationValueStrong; use style::gecko_bindings::bindings::RawServoStyleRuleBorrowed; -use style::gecko_bindings::bindings::RawServoStyleSheet; use style::gecko_bindings::bindings::ServoComputedValuesBorrowedOrNull; use style::gecko_bindings::bindings::nsTArrayBorrowed_uintptr_t; use style::gecko_bindings::bindings::nsTimingFunctionBorrowed; use style::gecko_bindings::bindings::nsTimingFunctionBorrowedMut; use style::gecko_bindings::structs; -use style::gecko_bindings::structs::{CSSPseudoElementType, CompositeOperation}; -use style::gecko_bindings::structs::{Loader, LoaderReusableStyleSheets}; +use style::gecko_bindings::structs::{CSSPseudoElementType, CompositeOperation, Loader}; use style::gecko_bindings::structs::{RawServoStyleRule, ServoStyleSheet}; use style::gecko_bindings::structs::{SheetParsingMode, nsIAtom, nsCSSPropertyID}; use style::gecko_bindings::structs::{nsCSSFontFaceRule, nsCSSCounterStyleRule}; @@ -105,7 +103,8 @@ use style::style_adjuster::StyleAdjuster; use style::stylearc::Arc; use style::stylesheets::{CssRule, CssRules, CssRuleType, CssRulesHelpers, DocumentRule}; use style::stylesheets::{ImportRule, KeyframesRule, MallocSizeOfWithGuard, MediaRule}; -use style::stylesheets::{NamespaceRule, Origin, PageRule, Stylesheet, StyleRule, SupportsRule}; +use style::stylesheets::{NamespaceRule, Origin, PageRule, StyleRule, SupportsRule}; +use style::stylesheets::StylesheetContents; use style::stylesheets::StylesheetLoader as StyleStylesheetLoader; use style::stylesheets::keyframes_rule::{Keyframe, KeyframeSelector, KeyframesStepValue}; use style::stylesheets::supports_rule::parse_condition_or_declaration; @@ -739,7 +738,7 @@ pub extern "C" fn Servo_Element_ClearData(element: RawGeckoElementBorrowed) { } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_Empty(mode: SheetParsingMode) -> RawServoStyleSheetStrong { +pub extern "C" fn Servo_StyleSheet_Empty(mode: SheetParsingMode) -> RawServoStyleSheetContentsStrong { let global_style_data = &*GLOBAL_STYLE_DATA; let origin = match mode { SheetParsingMode::eAuthorSheetFeatures => Origin::Author, @@ -747,24 +746,31 @@ pub extern "C" fn Servo_StyleSheet_Empty(mode: SheetParsingMode) -> RawServoStyl SheetParsingMode::eAgentSheetFeatures => Origin::UserAgent, SheetParsingMode::eSafeAgentSheetFeatures => Origin::UserAgent, }; - let shared_lock = global_style_data.shared_lock.clone(); - Arc::new(Stylesheet::from_str( - "", unsafe { dummy_url_data() }.clone(), origin, - Arc::new(shared_lock.wrap(MediaList::empty())), - shared_lock, None, &RustLogReporter, QuirksMode::NoQuirks, 0u64) + let shared_lock = &global_style_data.shared_lock; + Arc::new( + StylesheetContents::from_str( + "", + unsafe { dummy_url_data() }.clone(), + origin, + shared_lock, + /* loader = */ None, + &RustLogReporter, + QuirksMode::NoQuirks, + 0 + ) ).into_strong() } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_FromUTF8Bytes(loader: *mut Loader, - stylesheet: *mut ServoStyleSheet, - data: *const nsACString, - mode: SheetParsingMode, - media_list: *const RawServoMediaList, - extra_data: *mut URLExtraData, - line_number_offset: u32, - quirks_mode: nsCompatibility) - -> RawServoStyleSheetStrong { +pub extern "C" fn Servo_StyleSheet_FromUTF8Bytes( + loader: *mut Loader, + stylesheet: *mut ServoStyleSheet, + data: *const nsACString, + mode: SheetParsingMode, + extra_data: *mut URLExtraData, + line_number_offset: u32, + quirks_mode: nsCompatibility +) -> RawServoStyleSheetContentsStrong { let global_style_data = &*GLOBAL_STYLE_DATA; let input = unsafe { data.as_ref().unwrap().as_str_unchecked() }; @@ -788,63 +794,28 @@ pub extern "C" fn Servo_StyleSheet_FromUTF8Bytes(loader: *mut Loader, Some(ref s) => Some(s), }; - let shared_lock = global_style_data.shared_lock.clone(); - let media = if media_list.is_null() { - Arc::new(shared_lock.wrap(MediaList::empty())) - } else { - Locked::::as_arc(unsafe { &&*media_list }).clone() - }; - Arc::new(Stylesheet::from_str( - input, url_data.clone(), origin, media, - shared_lock, loader, &RustLogReporter, + Arc::new(StylesheetContents::from_str( + input, url_data.clone(), origin, + &global_style_data.shared_lock, loader, &RustLogReporter, quirks_mode.into(), line_number_offset as u64) ).into_strong() } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_ClearAndUpdate(stylesheet: RawServoStyleSheetBorrowed, - loader: *mut Loader, - gecko_stylesheet: *mut ServoStyleSheet, - data: *const nsACString, - extra_data: *mut URLExtraData, - line_number_offset: u32, - reusable_sheets: *mut LoaderReusableStyleSheets) -{ - let input = unsafe { data.as_ref().unwrap().as_str_unchecked() }; - let url_data = unsafe { RefPtr::from_ptr_ref(&extra_data) }; - - let loader = if loader.is_null() { - None - } else { - Some(StylesheetLoader::new(loader, gecko_stylesheet, reusable_sheets)) - }; - - // FIXME(emilio): loader.as_ref() doesn't typecheck for some reason? - let loader: Option<&StyleStylesheetLoader> = match loader { - None => None, - Some(ref s) => Some(s), - }; - - let sheet = Stylesheet::as_arc(&stylesheet); - Stylesheet::update_from_str(&sheet, input, url_data.clone(), loader, - &RustLogReporter, line_number_offset as u64); -} - -#[no_mangle] -pub extern "C" fn Servo_StyleSet_AppendStyleSheet(raw_data: RawServoStyleSetBorrowed, - raw_sheet: RawServoStyleSheetBorrowed, - unique_id: u64) { +pub extern "C" fn Servo_StyleSet_AppendStyleSheet( + raw_data: RawServoStyleSetBorrowed, + sheet: *const ServoStyleSheet, +) { let global_style_data = &*GLOBAL_STYLE_DATA; let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); let mut data = &mut *data; - let sheet = HasArcFFI::as_arc(&raw_sheet); let guard = global_style_data.shared_lock.read(); data.stylesheets.append_stylesheet( &data.stylist, - sheet, - unique_id, - &guard); + unsafe { GeckoStyleSheet::new(sheet) }, + &guard + ); data.clear_stylist(); } @@ -875,65 +846,55 @@ pub extern "C" fn Servo_StyleSet_MediumFeaturesChanged( } #[no_mangle] -pub extern "C" fn Servo_StyleSet_PrependStyleSheet(raw_data: RawServoStyleSetBorrowed, - raw_sheet: RawServoStyleSheetBorrowed, - unique_id: u64) { +pub extern "C" fn Servo_StyleSet_PrependStyleSheet( + raw_data: RawServoStyleSetBorrowed, + sheet: *const ServoStyleSheet, +) { let global_style_data = &*GLOBAL_STYLE_DATA; let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); let mut data = &mut *data; - let sheet = HasArcFFI::as_arc(&raw_sheet); let guard = global_style_data.shared_lock.read(); data.stylesheets.prepend_stylesheet( &data.stylist, - sheet, - unique_id, - &guard); + unsafe { GeckoStyleSheet::new(sheet) }, + &guard, + ); data.clear_stylist(); } #[no_mangle] -pub extern "C" fn Servo_StyleSet_InsertStyleSheetBefore(raw_data: RawServoStyleSetBorrowed, - raw_sheet: RawServoStyleSheetBorrowed, - unique_id: u64, - before_unique_id: u64) { +pub extern "C" fn Servo_StyleSet_InsertStyleSheetBefore( + raw_data: RawServoStyleSetBorrowed, + sheet: *const ServoStyleSheet, + before_sheet: *const ServoStyleSheet +) { let global_style_data = &*GLOBAL_STYLE_DATA; let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); let mut data = &mut *data; - let sheet = HasArcFFI::as_arc(&raw_sheet); let guard = global_style_data.shared_lock.read(); data.stylesheets.insert_stylesheet_before( &data.stylist, - sheet, - unique_id, - before_unique_id, + unsafe { GeckoStyleSheet::new(sheet) }, + unsafe { GeckoStyleSheet::new(before_sheet) }, &guard); data.clear_stylist(); } #[no_mangle] -pub extern "C" fn Servo_StyleSet_UpdateStyleSheet(raw_data: RawServoStyleSetBorrowed, - raw_sheet: RawServoStyleSheetBorrowed, - unique_id: u64) { +pub extern "C" fn Servo_StyleSet_RemoveStyleSheet( + raw_data: RawServoStyleSetBorrowed, + sheet: *const ServoStyleSheet +) { let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); - let sheet = HasArcFFI::as_arc(&raw_sheet); - data.stylesheets.update_stylesheet( - sheet, - unique_id); -} - -#[no_mangle] -pub extern "C" fn Servo_StyleSet_RemoveStyleSheet(raw_data: RawServoStyleSetBorrowed, - unique_id: u64) { - let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); - data.stylesheets.remove_stylesheet(unique_id); + data.stylesheets.remove_stylesheet(unsafe { GeckoStyleSheet::new(sheet) }); data.clear_stylist(); } #[no_mangle] pub extern "C" fn Servo_StyleSet_FlushStyleSheets( raw_data: RawServoStyleSetBorrowed, - doc_element: RawGeckoElementBorrowedOrNull) -{ + doc_element: RawGeckoElementBorrowedOrNull, +) { let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); @@ -944,8 +905,8 @@ pub extern "C" fn Servo_StyleSet_FlushStyleSheets( #[no_mangle] pub extern "C" fn Servo_StyleSet_NoteStyleSheetsChanged( raw_data: RawServoStyleSetBorrowed, - author_style_disabled: bool) -{ + author_style_disabled: bool, +) { let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); data.stylesheets.force_dirty(); data.stylesheets.set_author_style_disabled(author_style_disabled); @@ -953,30 +914,50 @@ pub extern "C" fn Servo_StyleSet_NoteStyleSheetsChanged( } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_HasRules(raw_sheet: RawServoStyleSheetBorrowed) -> bool { +pub extern "C" fn Servo_StyleSheet_HasRules( + raw_contents: RawServoStyleSheetContentsBorrowed +) -> bool { let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); - !Stylesheet::as_arc(&raw_sheet).rules.read_with(&guard).0.is_empty() + !StylesheetContents::as_arc(&raw_contents) + .rules.read_with(&guard).0.is_empty() } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_GetRules(sheet: RawServoStyleSheetBorrowed) -> ServoCssRulesStrong { - Stylesheet::as_arc(&sheet).rules.clone().into_strong() +pub extern "C" fn Servo_StyleSheet_GetRules( + sheet: RawServoStyleSheetContentsBorrowed +) -> ServoCssRulesStrong { + StylesheetContents::as_arc(&sheet).rules.clone().into_strong() } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_Clone(raw_sheet: RawServoStyleSheetBorrowed) -> RawServoStyleSheetStrong { - let sheet: &Arc = HasArcFFI::as_arc(&raw_sheet); - Arc::new(sheet.as_ref().clone()).into_strong() +pub extern "C" fn Servo_StyleSheet_Clone( + raw_sheet: RawServoStyleSheetContentsBorrowed, + reference_sheet: *const ServoStyleSheet, +) -> RawServoStyleSheetContentsStrong { + use style::shared_lock::{DeepCloneParams, DeepCloneWithLock}; + let global_style_data = &*GLOBAL_STYLE_DATA; + let guard = global_style_data.shared_lock.read(); + let contents = StylesheetContents::as_arc(&raw_sheet); + let params = DeepCloneParams { reference_sheet }; + + Arc::new(contents.deep_clone_with_lock( + &global_style_data.shared_lock, + &guard, + ¶ms, + )).into_strong() } #[no_mangle] -pub extern "C" fn Servo_StyleSheet_SizeOfIncludingThis(malloc_size_of: MallocSizeOf, - sheet: RawServoStyleSheetBorrowed) -> usize { +pub extern "C" fn Servo_StyleSheet_SizeOfIncludingThis( + malloc_size_of: MallocSizeOf, + sheet: RawServoStyleSheetContentsBorrowed +) -> usize { let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); let malloc_size_of = malloc_size_of.unwrap(); - Stylesheet::as_arc(&sheet).malloc_size_of_children(&guard, malloc_size_of) + StylesheetContents::as_arc(&sheet) + .malloc_size_of_children(&guard, malloc_size_of) } fn read_locked_arc(raw: & as HasFFI>::FFIType, func: F) -> R @@ -1008,15 +989,16 @@ pub extern "C" fn Servo_CssRules_ListTypes(rules: ServoCssRulesBorrowed, } #[no_mangle] -pub extern "C" fn Servo_CssRules_InsertRule(rules: ServoCssRulesBorrowed, - sheet: RawServoStyleSheetBorrowed, - rule: *const nsACString, - index: u32, - nested: bool, - loader: *mut Loader, - gecko_stylesheet: *mut ServoStyleSheet, - rule_type: *mut u16) -> nsresult { - let sheet = Stylesheet::as_arc(&sheet); +pub extern "C" fn Servo_CssRules_InsertRule( + rules: ServoCssRulesBorrowed, + contents: RawServoStyleSheetContentsBorrowed, + rule: *const nsACString, + index: u32, + nested: bool, + loader: *mut Loader, + gecko_stylesheet: *mut ServoStyleSheet, + rule_type: *mut u16, +) -> nsresult { let loader = if loader.is_null() { None } else { @@ -1026,12 +1008,17 @@ pub extern "C" fn Servo_CssRules_InsertRule(rules: ServoCssRulesBorrowed, let rule = unsafe { rule.as_ref().unwrap().as_str_unchecked() }; let global_style_data = &*GLOBAL_STYLE_DATA; - match Locked::::as_arc(&rules).insert_rule(&global_style_data.shared_lock, - rule, - sheet, - index as usize, - nested, - loader) { + let contents = StylesheetContents::as_arc(&contents); + let result = Locked::::as_arc(&rules).insert_rule( + &global_style_data.shared_lock, + rule, + contents, + index as usize, + nested, + loader + ); + + match result { Ok(new_rule) => { *unsafe { rule_type.as_mut().unwrap() } = new_rule.rule_type() as u16; nsresult::NS_OK @@ -1041,7 +1028,10 @@ pub extern "C" fn Servo_CssRules_InsertRule(rules: ServoCssRulesBorrowed, } #[no_mangle] -pub extern "C" fn Servo_CssRules_DeleteRule(rules: ServoCssRulesBorrowed, index: u32) -> nsresult { +pub extern "C" fn Servo_CssRules_DeleteRule( + rules: ServoCssRulesBorrowed, + index: u32 +) -> nsresult { write_locked_arc(rules, |rules: &mut CssRules| { match rules.remove_rule(index as usize) { Ok(_) => nsresult::NS_OK, @@ -1085,7 +1075,13 @@ macro_rules! impl_basic_rule_funcs { let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); let rules = Locked::::as_arc(&rules).read_with(&guard); - match rules.0[index as usize] { + let index = index as usize; + + if index >= rules.0.len() { + return Strong::null(); + } + + match rules.0[index] { CssRule::$name(ref rule) => { let location = rule.read_with(&guard).source_location; *unsafe { line.as_mut().unwrap() } = location.line as u32; @@ -1093,8 +1089,7 @@ macro_rules! impl_basic_rule_funcs { rule.clone().into_strong() }, _ => { - unreachable!(concat!(stringify!($getter), "should only be called ", - "on a ", stringify!($name), " rule")); + Strong::null() } } } @@ -1244,9 +1239,11 @@ pub extern "C" fn Servo_StyleRule_GetSelectorCount(rule: RawServoStyleRuleBorrow } #[no_mangle] -pub extern "C" fn Servo_StyleRule_GetSpecificityAtIndex(rule: RawServoStyleRuleBorrowed, - index: u32, - specificity: *mut u64) { +pub extern "C" fn Servo_StyleRule_GetSpecificityAtIndex( + rule: RawServoStyleRuleBorrowed, + index: u32, + specificity: *mut u64 +) { read_locked_arc(rule, |rule: &StyleRule| { let mut specificity = unsafe { specificity.as_mut().unwrap() }; let index = index as usize; @@ -1266,14 +1263,19 @@ pub extern "C" fn Servo_ImportRule_GetHref(rule: RawServoImportRuleBorrowed, res } #[no_mangle] -pub extern "C" fn Servo_ImportRule_GetSheet(rule: RawServoImportRuleBorrowed) -> *const RawServoStyleSheet { +pub extern "C" fn Servo_ImportRule_GetSheet( + rule: RawServoImportRuleBorrowed +) -> *const ServoStyleSheet { read_locked_arc(rule, |rule: &ImportRule| { - rule.stylesheet.as_borrowed_opt().unwrap() as *const _ + rule.stylesheet.0.raw() as *const ServoStyleSheet }) } #[no_mangle] -pub extern "C" fn Servo_Keyframe_GetKeyText(keyframe: RawServoKeyframeBorrowed, result: *mut nsAString) { +pub extern "C" fn Servo_Keyframe_GetKeyText( + keyframe: RawServoKeyframeBorrowed, + result: *mut nsAString +) { read_locked_arc(keyframe, |keyframe: &Keyframe| { keyframe.selector.to_css(unsafe { result.as_mut().unwrap() }).unwrap() }) @@ -1344,18 +1346,22 @@ pub extern "C" fn Servo_KeyframesRule_FindRule(rule: RawServoKeyframesRuleBorrow } #[no_mangle] -pub extern "C" fn Servo_KeyframesRule_AppendRule(rule: RawServoKeyframesRuleBorrowed, - sheet: RawServoStyleSheetBorrowed, - css: *const nsACString) -> bool { +pub extern "C" fn Servo_KeyframesRule_AppendRule( + rule: RawServoKeyframesRuleBorrowed, + contents: RawServoStyleSheetContentsBorrowed, + css: *const nsACString +) -> bool { let css = unsafe { css.as_ref().unwrap().as_str_unchecked() }; - let sheet = Stylesheet::as_arc(&sheet); - if let Ok(keyframe) = Keyframe::parse(css, sheet) { - write_locked_arc(rule, |rule: &mut KeyframesRule| { - rule.keyframes.push(keyframe); - }); - true - } else { - false + let contents = StylesheetContents::as_arc(&contents); + let global_style_data = &*GLOBAL_STYLE_DATA; + match Keyframe::parse(css, &contents, &global_style_data.shared_lock) { + Ok(keyframe) => { + write_locked_arc(rule, |rule: &mut KeyframesRule| { + rule.keyframes.push(keyframe); + }); + true + } + Err(..) => false, } } @@ -1607,10 +1613,10 @@ fn get_pseudo_style( #[no_mangle] pub extern "C" fn Servo_ComputedValues_Inherit( - raw_data: RawServoStyleSetBorrowed, - parent_style: ServoComputedValuesBorrowedOrNull, - target: structs::InheritTarget) - -> ServoComputedValuesStrong { + raw_data: RawServoStyleSetBorrowed, + parent_style: ServoComputedValuesBorrowedOrNull, + target: structs::InheritTarget +) -> ServoComputedValuesStrong { let data = PerDocumentStyleData::from_ffi(raw_data).borrow(); let maybe_arc = ComputedValues::arc_from_borrowed(&parent_style); @@ -3149,11 +3155,11 @@ pub extern "C" fn Servo_StyleSet_GetCounterStyleRule(raw_data: RawServoStyleSetB } #[no_mangle] -pub extern "C" fn Servo_StyleSet_ResolveForDeclarations(raw_data: RawServoStyleSetBorrowed, - parent_style_or_null: ServoComputedValuesBorrowedOrNull, - declarations: RawServoDeclarationBlockBorrowed) - -> ServoComputedValuesStrong -{ +pub extern "C" fn Servo_StyleSet_ResolveForDeclarations( + raw_data: RawServoStyleSetBorrowed, + parent_style_or_null: ServoComputedValuesBorrowedOrNull, + declarations: RawServoDeclarationBlockBorrowed +) -> ServoComputedValuesStrong { let doc_data = PerDocumentStyleData::from_ffi(raw_data).borrow(); let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); diff --git a/ports/geckolib/stylesheet_loader.rs b/ports/geckolib/stylesheet_loader.rs index 88a6866539c..57a0811c166 100644 --- a/ports/geckolib/stylesheet_loader.rs +++ b/ports/geckolib/stylesheet_loader.rs @@ -2,13 +2,18 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use cssparser::SourceLocation; +use style::gecko::data::GeckoStyleSheet; use style::gecko_bindings::bindings::Gecko_LoadStyleSheet; use style::gecko_bindings::structs::{Loader, ServoStyleSheet, LoaderReusableStyleSheets}; -use style::gecko_bindings::sugar::ownership::{HasArcFFI, FFIArcHelpers}; +use style::gecko_bindings::sugar::ownership::FFIArcHelpers; use style::media_queries::MediaList; -use style::shared_lock::Locked; +use style::parser::ParserContext; +use style::shared_lock::{Locked, SharedRwLock}; use style::stylearc::Arc; -use style::stylesheets::{ImportRule, Stylesheet, StylesheetLoader as StyleStylesheetLoader}; +use style::stylesheets::{ImportRule, StylesheetLoader as StyleStylesheetLoader}; +use style::stylesheets::import_rule::ImportSheet; +use style::values::specified::url::SpecifiedUrl; pub struct StylesheetLoader(*mut Loader, *mut ServoStyleSheet, *mut LoaderReusableStyleSheets); @@ -23,29 +28,34 @@ impl StylesheetLoader { impl StyleStylesheetLoader for StylesheetLoader { fn request_stylesheet( &self, + url: SpecifiedUrl, + source_location: SourceLocation, + _context: &ParserContext, + lock: &SharedRwLock, media: Arc>, - make_import: &mut FnMut(Arc>) -> ImportRule, - make_arc: &mut FnMut(ImportRule) -> Arc>, ) -> Arc> { - let import = make_import(media.clone()); - // After we get this raw pointer ImportRule will be moved into a lock and Arc // and so the Arc pointer inside will also move, // but the Url it points to or the allocating backing the String inside that Url won’t, // so this raw pointer will still be valid. - let (spec_bytes, spec_len): (*const u8, usize) = import.url.as_slice_components(); - let base_url_data = import.url.extra_data.get(); - unsafe { + let child_sheet = unsafe { + let (spec_bytes, spec_len) = url.as_slice_components(); + let base_url_data = url.extra_data.get(); Gecko_LoadStyleSheet(self.0, self.1, self.2, - Stylesheet::arc_as_borrowed(&import.stylesheet), base_url_data, spec_bytes, spec_len as u32, media.into_strong()) - } - make_arc(import) + }; + + debug_assert!(!child_sheet.is_null(), + "Import rules should always have a strong sheet"); + let stylesheet = unsafe { + ImportSheet(GeckoStyleSheet::from_addrefed(child_sheet)) + }; + Arc::new(lock.wrap(ImportRule { url, source_location, stylesheet })) } } diff --git a/tests/unit/style/media_queries.rs b/tests/unit/style/media_queries.rs index 62478a34b1c..3e091b8171e 100644 --- a/tests/unit/style/media_queries.rs +++ b/tests/unit/style/media_queries.rs @@ -13,7 +13,7 @@ use style::media_queries::*; use style::servo::media_queries::*; use style::shared_lock::SharedRwLock; use style::stylearc::Arc; -use style::stylesheets::{AllRules, Stylesheet, Origin, CssRule}; +use style::stylesheets::{AllRules, Stylesheet, StylesheetInDocument, Origin, CssRule}; use style::values::specified; use style_traits::ToCss; diff --git a/tests/unit/style/rule_tree/bench.rs b/tests/unit/style/rule_tree/bench.rs index ec67984631d..661dc76b63e 100644 --- a/tests/unit/style/rule_tree/bench.rs +++ b/tests/unit/style/rule_tree/bench.rs @@ -62,7 +62,7 @@ fn parse_rules(css: &str) -> Vec<(StyleSource, CascadeLevel)> { QuirksMode::NoQuirks, 0u64); let guard = s.shared_lock.read(); - let rules = s.rules.read_with(&guard); + let rules = s.contents.rules.read_with(&guard); rules.0.iter().filter_map(|rule| { match *rule { CssRule::Style(ref style_rule) => Some(style_rule), diff --git a/tests/unit/style/stylesheets.rs b/tests/unit/style/stylesheets.rs index 81f53e9b319..6761be36ff2 100644 --- a/tests/unit/style/stylesheets.rs +++ b/tests/unit/style/stylesheets.rs @@ -23,7 +23,7 @@ use style::properties::longhands::animation_play_state; use style::shared_lock::SharedRwLock; use style::stylearc::Arc; use style::stylesheets::{Origin, Namespaces}; -use style::stylesheets::{Stylesheet, NamespaceRule, CssRule, CssRules, StyleRule, KeyframesRule}; +use style::stylesheets::{Stylesheet, StylesheetContents, NamespaceRule, CssRule, CssRules, StyleRule, KeyframesRule}; use style::stylesheets::keyframes_rule::{Keyframe, KeyframeSelector, KeyframePercentage}; use style::values::{KeyframesName, CustomIdent}; use style::values::specified::{LengthOrPercentageOrAuto, Percentage, PositionComponent}; @@ -72,176 +72,178 @@ fn test_parse_stylesheet() { let mut namespaces = Namespaces::default(); namespaces.default = Some((ns!(html), ())); let expected = Stylesheet { - origin: Origin::UserAgent, - media: Arc::new(stylesheet.shared_lock.wrap(MediaList::empty())), - shared_lock: stylesheet.shared_lock.clone(), - namespaces: RwLock::new(namespaces), - url_data: RwLock::new(url), - dirty_on_viewport_size_change: AtomicBool::new(false), - disabled: AtomicBool::new(false), - quirks_mode: QuirksMode::NoQuirks, - rules: CssRules::new(vec![ - CssRule::Namespace(Arc::new(stylesheet.shared_lock.wrap(NamespaceRule { - prefix: None, - url: NsAtom::from("http://www.w3.org/1999/xhtml"), - source_location: SourceLocation { - line: 1, - column: 19, - }, - }))), - CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { - selectors: SelectorList::from_vec(vec!( - Selector::from_vec(vec!( - Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), - Component::LocalName(LocalName { - name: local_name!("input"), - lower_name: local_name!("input"), - }), - Component::AttributeInNoNamespace { - local_name: local_name!("type"), - local_name_lower: local_name!("type"), - operator: AttrSelectorOperator::Equal, - value: "hidden".to_owned(), - case_sensitivity: ParsedCaseSensitivity::AsciiCaseInsensitive, - never_matches: false, - } - ), (0 << 20) + (1 << 10) + (1 << 0)) - )), - block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ - (PropertyDeclaration::Display(longhands::display::SpecifiedValue::none), - Importance::Important), - (PropertyDeclaration::Custom(Atom::from("a"), - DeclaredValueOwned::CSSWideKeyword(CSSWideKeyword::Inherit)), - Importance::Important), - ]))), - source_location: SourceLocation { - line: 3, - column: 9, - }, - }))), - CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { - selectors: SelectorList::from_vec(vec!( - Selector::from_vec(vec!( + contents: StylesheetContents { + origin: Origin::UserAgent, + namespaces: RwLock::new(namespaces), + url_data: RwLock::new(url), + dirty_on_viewport_size_change: AtomicBool::new(false), + quirks_mode: QuirksMode::NoQuirks, + rules: CssRules::new(vec![ + CssRule::Namespace(Arc::new(stylesheet.shared_lock.wrap(NamespaceRule { + prefix: None, + url: NsAtom::from("http://www.w3.org/1999/xhtml"), + source_location: SourceLocation { + line: 1, + column: 19, + }, + }))), + CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { + selectors: SelectorList::from_vec(vec!( + Selector::from_vec(vec!( Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), Component::LocalName(LocalName { - name: local_name!("html"), - lower_name: local_name!("html"), + name: local_name!("input"), + lower_name: local_name!("input"), }), - ), (0 << 20) + (0 << 10) + (1 << 0)), - Selector::from_vec(vec!( - Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), - Component::LocalName(LocalName { - name: local_name!("body"), - lower_name: local_name!("body"), - }) - ), (0 << 20) + (0 << 10) + (1 << 0) - ), - )), - block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ - (PropertyDeclaration::Display(longhands::display::SpecifiedValue::block), - Importance::Normal), - ]))), - source_location: SourceLocation { - line: 11, - column: 9, - }, - }))), - CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { - selectors: SelectorList::from_vec(vec!( - Selector::from_vec(vec!( - Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), - Component::ID(Atom::from("d1")), - Component::Combinator(Combinator::Child), - Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), - Component::Class(Atom::from("ok")) - ), (1 << 20) + (1 << 10) + (0 << 0)) - )), - block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ - (PropertyDeclaration::BackgroundColor( - longhands::background_color::SpecifiedValue::Numeric { - authored: Some("blue".to_owned().into_boxed_str()), - parsed: cssparser::RGBA::new(0, 0, 255, 255), - } - ), - Importance::Normal), - (PropertyDeclaration::BackgroundPositionX( - longhands::background_position_x::SpecifiedValue( - vec![PositionComponent::zero()])), - Importance::Normal), - (PropertyDeclaration::BackgroundPositionY( - longhands::background_position_y::SpecifiedValue( - vec![PositionComponent::zero()])), - Importance::Normal), - (PropertyDeclaration::BackgroundRepeat( - longhands::background_repeat::SpecifiedValue( - vec![longhands::background_repeat::single_value - ::get_initial_specified_value()])), - Importance::Normal), - (PropertyDeclaration::BackgroundAttachment( - longhands::background_attachment::SpecifiedValue( - vec![longhands::background_attachment::single_value - ::get_initial_specified_value()])), - Importance::Normal), - (PropertyDeclaration::BackgroundImage( - longhands::background_image::SpecifiedValue( - vec![longhands::background_image::single_value - ::get_initial_specified_value()])), - Importance::Normal), - (PropertyDeclaration::BackgroundSize( - longhands::background_size::SpecifiedValue( - vec![longhands::background_size::single_value - ::get_initial_specified_value()])), - Importance::Normal), - (PropertyDeclaration::BackgroundOrigin( - longhands::background_origin::SpecifiedValue( - vec![longhands::background_origin::single_value - ::get_initial_specified_value()])), - Importance::Normal), - (PropertyDeclaration::BackgroundClip( - longhands::background_clip::SpecifiedValue( - vec![longhands::background_clip::single_value - ::get_initial_specified_value()])), - Importance::Normal), - ]))), - source_location: SourceLocation { - line: 15, - column: 9, - }, - }))), - CssRule::Keyframes(Arc::new(stylesheet.shared_lock.wrap(KeyframesRule { - name: KeyframesName::Ident(CustomIdent("foo".into())), - keyframes: vec![ - Arc::new(stylesheet.shared_lock.wrap(Keyframe { - selector: KeyframeSelector::new_for_unit_testing( - vec![KeyframePercentage::new(0.)]), - block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ - (PropertyDeclaration::Width( - LengthOrPercentageOrAuto::Percentage(Percentage(0.))), - Importance::Normal), - ]))) - })), - Arc::new(stylesheet.shared_lock.wrap(Keyframe { - selector: KeyframeSelector::new_for_unit_testing( - vec![KeyframePercentage::new(1.)]), - block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ - (PropertyDeclaration::Width( - LengthOrPercentageOrAuto::Percentage(Percentage(1.))), - Importance::Normal), - (PropertyDeclaration::AnimationPlayState( - animation_play_state::SpecifiedValue( - vec![animation_play_state::SingleSpecifiedValue::running])), - Importance::Normal), - ]))), - })), - ], - vendor_prefix: None, - source_location: SourceLocation { - line: 16, - column: 19, - }, - }))) + Component::AttributeInNoNamespace { + local_name: local_name!("type"), + local_name_lower: local_name!("type"), + operator: AttrSelectorOperator::Equal, + value: "hidden".to_owned(), + case_sensitivity: ParsedCaseSensitivity::AsciiCaseInsensitive, + never_matches: false, + } + ), (0 << 20) + (1 << 10) + (1 << 0)) + )), + block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ + (PropertyDeclaration::Display(longhands::display::SpecifiedValue::none), + Importance::Important), + (PropertyDeclaration::Custom(Atom::from("a"), + DeclaredValueOwned::CSSWideKeyword(CSSWideKeyword::Inherit)), + Importance::Important), + ]))), + source_location: SourceLocation { + line: 3, + column: 9, + }, + }))), + CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { + selectors: SelectorList::from_vec(vec!( + Selector::from_vec(vec!( + Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), + Component::LocalName(LocalName { + name: local_name!("html"), + lower_name: local_name!("html"), + }), + ), (0 << 20) + (0 << 10) + (1 << 0)), + Selector::from_vec(vec!( + Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), + Component::LocalName(LocalName { + name: local_name!("body"), + lower_name: local_name!("body"), + }) + ), (0 << 20) + (0 << 10) + (1 << 0) + ), + )), + block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ + (PropertyDeclaration::Display(longhands::display::SpecifiedValue::block), + Importance::Normal), + ]))), + source_location: SourceLocation { + line: 11, + column: 9, + }, + }))), + CssRule::Style(Arc::new(stylesheet.shared_lock.wrap(StyleRule { + selectors: SelectorList::from_vec(vec!( + Selector::from_vec(vec!( + Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), + Component::ID(Atom::from("d1")), + Component::Combinator(Combinator::Child), + Component::DefaultNamespace(NsAtom::from("http://www.w3.org/1999/xhtml")), + Component::Class(Atom::from("ok")) + ), (1 << 20) + (1 << 10) + (0 << 0)) + )), + block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ + (PropertyDeclaration::BackgroundColor( + longhands::background_color::SpecifiedValue::Numeric { + authored: Some("blue".to_owned().into_boxed_str()), + parsed: cssparser::RGBA::new(0, 0, 255, 255), + } + ), + Importance::Normal), + (PropertyDeclaration::BackgroundPositionX( + longhands::background_position_x::SpecifiedValue( + vec![PositionComponent::zero()])), + Importance::Normal), + (PropertyDeclaration::BackgroundPositionY( + longhands::background_position_y::SpecifiedValue( + vec![PositionComponent::zero()])), + Importance::Normal), + (PropertyDeclaration::BackgroundRepeat( + longhands::background_repeat::SpecifiedValue( + vec![longhands::background_repeat::single_value + ::get_initial_specified_value()])), + Importance::Normal), + (PropertyDeclaration::BackgroundAttachment( + longhands::background_attachment::SpecifiedValue( + vec![longhands::background_attachment::single_value + ::get_initial_specified_value()])), + Importance::Normal), + (PropertyDeclaration::BackgroundImage( + longhands::background_image::SpecifiedValue( + vec![longhands::background_image::single_value + ::get_initial_specified_value()])), + Importance::Normal), + (PropertyDeclaration::BackgroundSize( + longhands::background_size::SpecifiedValue( + vec![longhands::background_size::single_value + ::get_initial_specified_value()])), + Importance::Normal), + (PropertyDeclaration::BackgroundOrigin( + longhands::background_origin::SpecifiedValue( + vec![longhands::background_origin::single_value + ::get_initial_specified_value()])), + Importance::Normal), + (PropertyDeclaration::BackgroundClip( + longhands::background_clip::SpecifiedValue( + vec![longhands::background_clip::single_value + ::get_initial_specified_value()])), + Importance::Normal), + ]))), + source_location: SourceLocation { + line: 15, + column: 9, + }, + }))), + CssRule::Keyframes(Arc::new(stylesheet.shared_lock.wrap(KeyframesRule { + name: KeyframesName::Ident(CustomIdent("foo".into())), + keyframes: vec![ + Arc::new(stylesheet.shared_lock.wrap(Keyframe { + selector: KeyframeSelector::new_for_unit_testing( + vec![KeyframePercentage::new(0.)]), + block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ + (PropertyDeclaration::Width( + LengthOrPercentageOrAuto::Percentage(Percentage(0.))), + Importance::Normal), + ]))) + })), + Arc::new(stylesheet.shared_lock.wrap(Keyframe { + selector: KeyframeSelector::new_for_unit_testing( + vec![KeyframePercentage::new(1.)]), + block: Arc::new(stylesheet.shared_lock.wrap(block_from(vec![ + (PropertyDeclaration::Width( + LengthOrPercentageOrAuto::Percentage(Percentage(1.))), + Importance::Normal), + (PropertyDeclaration::AnimationPlayState( + animation_play_state::SpecifiedValue( + vec![animation_play_state::SingleSpecifiedValue::running])), + Importance::Normal), + ]))), + })), + ], + vendor_prefix: None, + source_location: SourceLocation { + line: 16, + column: 19, + }, + }))) - ], &stylesheet.shared_lock), + ], &stylesheet.shared_lock), + }, + media: Arc::new(stylesheet.shared_lock.wrap(MediaList::empty())), + shared_lock: stylesheet.shared_lock.clone(), + disabled: AtomicBool::new(false), }; assert_eq!(format!("{:#?}", stylesheet), format!("{:#?}", expected)); diff --git a/tests/unit/style/viewport.rs b/tests/unit/style/viewport.rs index e6c8df4aaf4..cb82ee6d65f 100644 --- a/tests/unit/style/viewport.rs +++ b/tests/unit/style/viewport.rs @@ -12,7 +12,7 @@ use style::media_queries::{Device, MediaList, MediaType}; use style::parser::{Parse, ParserContext}; use style::shared_lock::SharedRwLock; use style::stylearc::Arc; -use style::stylesheets::{CssRuleType, Stylesheet, Origin}; +use style::stylesheets::{CssRuleType, Stylesheet, StylesheetInDocument, Origin}; use style::stylesheets::viewport_rule::*; use style::values::specified::LengthOrPercentageOrAuto::{self, Auto}; use style::values::specified::NoCalcLength::{self, ViewportPercentage}; @@ -269,7 +269,11 @@ fn multiple_stylesheets_cascading() { Author, error_reporter, shared_lock.clone()) ]; - let declarations = Cascade::from_stylesheets(stylesheets.iter(), &shared_lock.read(), &device).finish(); + let declarations = Cascade::from_stylesheets( + stylesheets.iter().map(|s| &**s), + &shared_lock.read(), + &device, + ).finish(); assert_decl_len!(declarations == 3); assert_decl_eq!(&declarations[0], UserAgent, Zoom: Zoom::Number(1.)); assert_decl_eq!(&declarations[1], User, MinHeight: viewport_length!(200., px)); @@ -283,7 +287,11 @@ fn multiple_stylesheets_cascading() { stylesheet!("@viewport { min-width: 300px !important; min-height: 300px !important; zoom: 3 !important; }", Author, error_reporter, shared_lock.clone()) ]; - let declarations = Cascade::from_stylesheets(stylesheets.iter(), &shared_lock.read(), &device).finish(); + let declarations = Cascade::from_stylesheets( + stylesheets.iter().map(|s| &**s), + &shared_lock.read(), + &device, + ).finish(); assert_decl_len!(declarations == 3); assert_decl_eq!(&declarations[0], UserAgent, MinWidth: viewport_length!(100., px), !important); assert_decl_eq!(&declarations[1], User, MinHeight: viewport_length!(200., px), !important);