diff options
-rw-r--r-- | components/style/binding_tools/.gitignore | 2 | ||||
-rw-r--r-- | components/style/binding_tools/README.md | 7 | ||||
-rwxr-xr-x | components/style/binding_tools/setup_bindgen.sh | 30 | ||||
-rw-r--r-- | components/style/build_gecko.rs | 3 | ||||
-rw-r--r-- | components/style/gecko/generated/bindings.rs | 23 | ||||
-rw-r--r-- | components/style/gecko/generated/pseudo_element_definition.rs | 1252 | ||||
-rw-r--r-- | components/style/gecko/generated/pseudo_element_helper.rs | 280 | ||||
-rw-r--r-- | components/style/gecko/generated/structs_debug.rs | 789 | ||||
-rw-r--r-- | components/style/gecko/generated/structs_release.rs | 802 | ||||
-rw-r--r-- | components/style/gecko/mod.rs | 1 | ||||
-rw-r--r-- | components/style/gecko/pseudo_element.rs | 71 | ||||
-rw-r--r-- | components/style/gecko/pseudo_element_definition.mako.rs | 128 | ||||
-rwxr-xr-x | components/style/gecko/regen_atoms.py (renamed from components/style/binding_tools/regen_atoms.py) | 70 | ||||
-rw-r--r-- | components/style/gecko/selector_parser.rs | 214 | ||||
-rw-r--r-- | components/style/gecko/wrapper.rs | 13 | ||||
-rw-r--r-- | ports/geckolib/glue.rs | 35 | ||||
-rw-r--r-- | tests/unit/stylo/sanity_checks.rs | 25 |
17 files changed, 2250 insertions, 1495 deletions
diff --git a/components/style/binding_tools/.gitignore b/components/style/binding_tools/.gitignore deleted file mode 100644 index ba50cb6cd5d..00000000000 --- a/components/style/binding_tools/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -llvm/ -rust-bindgen/ diff --git a/components/style/binding_tools/README.md b/components/style/binding_tools/README.md deleted file mode 100644 index e1465143e32..00000000000 --- a/components/style/binding_tools/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# Geckolib tools - -This directory contains simple tools for generating the Rust bindings for [stylo](https://public.etherpad-mozilla.org/p/stylo). - -## `setup_bindgen.sh` - -This clones Servo's version of bindgen, and uses `llvm-3.8` library to build it. It will then be used to generate the Rust bindings. diff --git a/components/style/binding_tools/setup_bindgen.sh b/components/style/binding_tools/setup_bindgen.sh deleted file mode 100755 index 4447b2ccda3..00000000000 --- a/components/style/binding_tools/setup_bindgen.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/usr/bin/env bash - -# This Source Code Form is subject to the terms of the Mozilla Public -# 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/. - -set -o errexit -set -o nounset -set -o pipefail - -# Run in the tools directory. -cd "$(dirname ${0})" - -# Setup and build bindgen. -if [[ "$(uname)" == "Linux" ]]; then - export LIBCLANG_PATH=/usr/lib/llvm-3.8/lib -else - export LIBCLANG_PATH="$(brew --prefix llvm38)/lib/llvm-3.8/lib" -fi - -# Make sure we have llvm-3.8. -if [[ ! -x "$(command -v clang-3.8)" ]]; then - echo "llvm-3.8 is required." \ - "Mac users should |brew install llvm38|," \ - "Linux users can find it in clang-3.8." - exit 1 -fi - -export LD_LIBRARY_PATH="${LIBCLANG_PATH}" -export DYLD_LIBRARY_PATH="${LIBCLANG_PATH}" diff --git a/components/style/build_gecko.rs b/components/style/build_gecko.rs index 8c4b852290a..462c1545739 100644 --- a/components/style/build_gecko.rs +++ b/components/style/build_gecko.rs @@ -672,6 +672,7 @@ mod bindings { "RawGeckoURLExtraData", "RefPtr", "CSSPseudoClassType", + "CSSPseudoElementType", "TraversalRestyleBehavior", "TraversalRootBehavior", "ComputedTimingFunction_BeforeFlag", @@ -842,7 +843,7 @@ mod bindings { } fn generate_atoms() { - let script = Path::new(file!()).parent().unwrap().join("binding_tools").join("regen_atoms.py"); + let script = Path::new(file!()).parent().unwrap().join("gecko").join("regen_atoms.py"); println!("cargo:rerun-if-changed={}", script.display()); let status = Command::new(&*PYTHON) .arg(&script) diff --git a/components/style/gecko/generated/bindings.rs b/components/style/gecko/generated/bindings.rs index 62e1797dcb5..ed00d8cd94f 100644 --- a/components/style/gecko/generated/bindings.rs +++ b/components/style/gecko/generated/bindings.rs @@ -26,6 +26,7 @@ use gecko_bindings::structs::RawGeckoServoStyleRuleList; use gecko_bindings::structs::RawGeckoURLExtraData; use gecko_bindings::structs::RefPtr; use gecko_bindings::structs::CSSPseudoClassType; +use gecko_bindings::structs::CSSPseudoElementType; use gecko_bindings::structs::TraversalRestyleBehavior; use gecko_bindings::structs::TraversalRootBehavior; use gecko_bindings::structs::ComputedTimingFunction_BeforeFlag; @@ -905,7 +906,7 @@ extern "C" { } extern "C" { pub fn Gecko_GetImplementedPseudo(element: RawGeckoElementBorrowed) - -> *mut nsIAtom; + -> CSSPseudoElementType; } extern "C" { pub fn Gecko_CalcStyleDifference(oldstyle: *mut nsStyleContext, @@ -2217,7 +2218,7 @@ extern "C" { extern "C" { pub fn Servo_ComputedValues_GetForAnonymousBox(parent_style_or_null: ServoComputedValuesBorrowedOrNull, - pseudoTag: *mut nsIAtom, + pseudo_tag: *mut nsIAtom, skip_display_fixup: bool, set: RawServoStyleSetBorrowed) @@ -2257,25 +2258,19 @@ extern "C" { } extern "C" { pub fn Servo_ResolvePseudoStyle(element: RawGeckoElementBorrowed, - pseudo_tag: *mut nsIAtom, is_probe: bool, + pseudo_type: CSSPseudoElementType, + is_probe: bool, set: RawServoStyleSetBorrowed) -> ServoComputedValuesStrong; } extern "C" { - pub fn Servo_ResolveRuleNode(element: RawGeckoElementBorrowed, - pseudo_tag: *mut nsIAtom, - set: RawServoStyleSetBorrowed) - -> RawServoRuleNodeStrong; -} -extern "C" { - pub fn Servo_HasAuthorSpecifiedRules(rule_node: RawServoRuleNodeBorrowed, - element: RawGeckoElementBorrowed, + pub fn Servo_HasAuthorSpecifiedRules(element: RawGeckoElementBorrowed, rule_type_mask: u32, author_colors_allowed: bool) -> bool; } extern "C" { pub fn Servo_ResolveStyleLazily(element: RawGeckoElementBorrowed, - pseudo_tag: *mut nsIAtom, + pseudo_type: CSSPseudoElementType, snapshots: *const ServoElementSnapshotTable, set: RawServoStyleSetBorrowed) @@ -2299,8 +2294,8 @@ extern "C" { RawGeckoElementBorrowed, snapshots: *const ServoElementSnapshotTable, - pseudo_tag: - *mut nsIAtom) + pseudo_type: + CSSPseudoElementType) -> ServoComputedValuesStrong; } extern "C" { diff --git a/components/style/gecko/generated/pseudo_element_definition.rs b/components/style/gecko/generated/pseudo_element_definition.rs new file mode 100644 index 00000000000..c733aa08f8b --- /dev/null +++ b/components/style/gecko/generated/pseudo_element_definition.rs @@ -0,0 +1,1252 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * 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/. */ + +/// Gecko's pseudo-element definition. +#[derive(Clone, Debug, PartialEq, Eq, Hash)] +pub enum PseudoElement { + /// :after + After, + /// :before + Before, + /// :backdrop + Backdrop, + /// :cue + Cue, + /// :first-letter + FirstLetter, + /// :first-line + FirstLine, + /// :-moz-selection + MozSelection, + /// :-moz-focus-inner + MozFocusInner, + /// :-moz-focus-outer + MozFocusOuter, + /// :-moz-list-bullet + MozListBullet, + /// :-moz-list-number + MozListNumber, + /// :-moz-math-anonymous + MozMathAnonymous, + /// :-moz-number-wrapper + MozNumberWrapper, + /// :-moz-number-text + MozNumberText, + /// :-moz-number-spin-box + MozNumberSpinBox, + /// :-moz-number-spin-up + MozNumberSpinUp, + /// :-moz-number-spin-down + MozNumberSpinDown, + /// :-moz-progress-bar + MozProgressBar, + /// :-moz-range-track + MozRangeTrack, + /// :-moz-range-progress + MozRangeProgress, + /// :-moz-range-thumb + MozRangeThumb, + /// :-moz-meter-bar + MozMeterBar, + /// :-moz-placeholder + MozPlaceholder, + /// :placeholder + Placeholder, + /// :-moz-color-swatch + MozColorSwatch, + /// :-moz-text + MozText, + /// :-moz-oof-placeholder + OofPlaceholder, + /// :-moz-first-letter-continuation + FirstLetterContinuation, + /// :-moz-block-inside-inline-wrapper + MozBlockInsideInlineWrapper, + /// :-moz-mathml-anonymous-block + MozMathMLAnonymousBlock, + /// :-moz-xul-anonymous-block + MozXULAnonymousBlock, + /// :-moz-hframeset-border + HorizontalFramesetBorder, + /// :-moz-vframeset-border + VerticalFramesetBorder, + /// :-moz-line-frame + MozLineFrame, + /// :-moz-button-content + ButtonContent, + /// :-moz-cell-content + CellContent, + /// :-moz-dropdown-list + DropDownList, + /// :-moz-fieldset-content + FieldsetContent, + /// :-moz-frameset-blank + FramesetBlank, + /// :-moz-display-comboboxcontrol-frame + MozDisplayComboboxControlFrame, + /// :-moz-html-canvas-content + HtmlCanvasContent, + /// :-moz-inline-table + InlineTable, + /// :-moz-table + Table, + /// :-moz-table-cell + TableCell, + /// :-moz-table-column-group + TableColGroup, + /// :-moz-table-column + TableCol, + /// :-moz-table-wrapper + TableWrapper, + /// :-moz-table-row-group + TableRowGroup, + /// :-moz-table-row + TableRow, + /// :-moz-canvas + Canvas, + /// :-moz-pagebreak + PageBreak, + /// :-moz-page + Page, + /// :-moz-pagecontent + PageContent, + /// :-moz-page-sequence + PageSequence, + /// :-moz-scrolled-content + ScrolledContent, + /// :-moz-scrolled-canvas + ScrolledCanvas, + /// :-moz-scrolled-page-sequence + ScrolledPageSequence, + /// :-moz-column-content + ColumnContent, + /// :-moz-viewport + Viewport, + /// :-moz-viewport-scroll + ViewportScroll, + /// :-moz-anonymous-flex-item + AnonymousFlexItem, + /// :-moz-anonymous-grid-item + AnonymousGridItem, + /// :-moz-ruby + Ruby, + /// :-moz-ruby-base + RubyBase, + /// :-moz-ruby-base-container + RubyBaseContainer, + /// :-moz-ruby-text + RubyText, + /// :-moz-ruby-text-container + RubyTextContainer, + /// :-moz-tree-column + Moztreecolumn, + /// :-moz-tree-row + Moztreerow, + /// :-moz-tree-separator + Moztreeseparator, + /// :-moz-tree-cell + Moztreecell, + /// :-moz-tree-indentation + Moztreeindentation, + /// :-moz-tree-line + Moztreeline, + /// :-moz-tree-twisty + Moztreetwisty, + /// :-moz-tree-image + Moztreeimage, + /// :-moz-tree-cell-text + Moztreecelltext, + /// :-moz-tree-checkbox + Moztreecheckbox, + /// :-moz-tree-progressmeter + Moztreeprogressmeter, + /// :-moz-tree-drop-feedback + Moztreedropfeedback, + /// :-moz-svg-marker-anon-child + MozSVGMarkerAnonChild, + /// :-moz-svg-outer-svg-anon-child + MozSVGOuterSVGAnonChild, + /// :-moz-svg-foreign-content + MozSVGForeignContent, + /// :-moz-svg-text + MozSVGText, +} + + + +/// The number of eager pseudo-elements. +pub const EAGER_PSEUDO_COUNT: usize = 2; + +/// The list of eager pseudos. +pub const EAGER_PSEUDOS: [PseudoElement; EAGER_PSEUDO_COUNT] = [ + PseudoElement::Before, + PseudoElement::After, +]; + +impl PseudoElement { + /// Executes a closure with each pseudo-element as an argument. + pub fn each<F>(mut fun: F) + where F: FnMut(Self), + { + fun(PseudoElement::After); + fun(PseudoElement::Before); + fun(PseudoElement::Backdrop); + fun(PseudoElement::Cue); + fun(PseudoElement::FirstLetter); + fun(PseudoElement::FirstLine); + fun(PseudoElement::MozSelection); + fun(PseudoElement::MozFocusInner); + fun(PseudoElement::MozFocusOuter); + fun(PseudoElement::MozListBullet); + fun(PseudoElement::MozListNumber); + fun(PseudoElement::MozMathAnonymous); + fun(PseudoElement::MozNumberWrapper); + fun(PseudoElement::MozNumberText); + fun(PseudoElement::MozNumberSpinBox); + fun(PseudoElement::MozNumberSpinUp); + fun(PseudoElement::MozNumberSpinDown); + fun(PseudoElement::MozProgressBar); + fun(PseudoElement::MozRangeTrack); + fun(PseudoElement::MozRangeProgress); + fun(PseudoElement::MozRangeThumb); + fun(PseudoElement::MozMeterBar); + fun(PseudoElement::MozPlaceholder); + fun(PseudoElement::Placeholder); + fun(PseudoElement::MozColorSwatch); + fun(PseudoElement::MozText); + fun(PseudoElement::OofPlaceholder); + fun(PseudoElement::FirstLetterContinuation); + fun(PseudoElement::MozBlockInsideInlineWrapper); + fun(PseudoElement::MozMathMLAnonymousBlock); + fun(PseudoElement::MozXULAnonymousBlock); + fun(PseudoElement::HorizontalFramesetBorder); + fun(PseudoElement::VerticalFramesetBorder); + fun(PseudoElement::MozLineFrame); + fun(PseudoElement::ButtonContent); + fun(PseudoElement::CellContent); + fun(PseudoElement::DropDownList); + fun(PseudoElement::FieldsetContent); + fun(PseudoElement::FramesetBlank); + fun(PseudoElement::MozDisplayComboboxControlFrame); + fun(PseudoElement::HtmlCanvasContent); + fun(PseudoElement::InlineTable); + fun(PseudoElement::Table); + fun(PseudoElement::TableCell); + fun(PseudoElement::TableColGroup); + fun(PseudoElement::TableCol); + fun(PseudoElement::TableWrapper); + fun(PseudoElement::TableRowGroup); + fun(PseudoElement::TableRow); + fun(PseudoElement::Canvas); + fun(PseudoElement::PageBreak); + fun(PseudoElement::Page); + fun(PseudoElement::PageContent); + fun(PseudoElement::PageSequence); + fun(PseudoElement::ScrolledContent); + fun(PseudoElement::ScrolledCanvas); + fun(PseudoElement::ScrolledPageSequence); + fun(PseudoElement::ColumnContent); + fun(PseudoElement::Viewport); + fun(PseudoElement::ViewportScroll); + fun(PseudoElement::AnonymousFlexItem); + fun(PseudoElement::AnonymousGridItem); + fun(PseudoElement::Ruby); + fun(PseudoElement::RubyBase); + fun(PseudoElement::RubyBaseContainer); + fun(PseudoElement::RubyText); + fun(PseudoElement::RubyTextContainer); + fun(PseudoElement::Moztreecolumn); + fun(PseudoElement::Moztreerow); + fun(PseudoElement::Moztreeseparator); + fun(PseudoElement::Moztreecell); + fun(PseudoElement::Moztreeindentation); + fun(PseudoElement::Moztreeline); + fun(PseudoElement::Moztreetwisty); + fun(PseudoElement::Moztreeimage); + fun(PseudoElement::Moztreecelltext); + fun(PseudoElement::Moztreecheckbox); + fun(PseudoElement::Moztreeprogressmeter); + fun(PseudoElement::Moztreedropfeedback); + fun(PseudoElement::MozSVGMarkerAnonChild); + fun(PseudoElement::MozSVGOuterSVGAnonChild); + fun(PseudoElement::MozSVGForeignContent); + fun(PseudoElement::MozSVGText); + } + + /// Get the pseudo-element as an atom. + #[inline] + pub fn atom(&self) -> Atom { + match *self { + PseudoElement::After => atom!(":after"), + PseudoElement::Before => atom!(":before"), + PseudoElement::Backdrop => atom!(":backdrop"), + PseudoElement::Cue => atom!(":cue"), + PseudoElement::FirstLetter => atom!(":first-letter"), + PseudoElement::FirstLine => atom!(":first-line"), + PseudoElement::MozSelection => atom!(":-moz-selection"), + PseudoElement::MozFocusInner => atom!(":-moz-focus-inner"), + PseudoElement::MozFocusOuter => atom!(":-moz-focus-outer"), + PseudoElement::MozListBullet => atom!(":-moz-list-bullet"), + PseudoElement::MozListNumber => atom!(":-moz-list-number"), + PseudoElement::MozMathAnonymous => atom!(":-moz-math-anonymous"), + PseudoElement::MozNumberWrapper => atom!(":-moz-number-wrapper"), + PseudoElement::MozNumberText => atom!(":-moz-number-text"), + PseudoElement::MozNumberSpinBox => atom!(":-moz-number-spin-box"), + PseudoElement::MozNumberSpinUp => atom!(":-moz-number-spin-up"), + PseudoElement::MozNumberSpinDown => atom!(":-moz-number-spin-down"), + PseudoElement::MozProgressBar => atom!(":-moz-progress-bar"), + PseudoElement::MozRangeTrack => atom!(":-moz-range-track"), + PseudoElement::MozRangeProgress => atom!(":-moz-range-progress"), + PseudoElement::MozRangeThumb => atom!(":-moz-range-thumb"), + PseudoElement::MozMeterBar => atom!(":-moz-meter-bar"), + PseudoElement::MozPlaceholder => atom!(":-moz-placeholder"), + PseudoElement::Placeholder => atom!(":placeholder"), + PseudoElement::MozColorSwatch => atom!(":-moz-color-swatch"), + PseudoElement::MozText => atom!(":-moz-text"), + PseudoElement::OofPlaceholder => atom!(":-moz-oof-placeholder"), + PseudoElement::FirstLetterContinuation => atom!(":-moz-first-letter-continuation"), + PseudoElement::MozBlockInsideInlineWrapper => atom!(":-moz-block-inside-inline-wrapper"), + PseudoElement::MozMathMLAnonymousBlock => atom!(":-moz-mathml-anonymous-block"), + PseudoElement::MozXULAnonymousBlock => atom!(":-moz-xul-anonymous-block"), + PseudoElement::HorizontalFramesetBorder => atom!(":-moz-hframeset-border"), + PseudoElement::VerticalFramesetBorder => atom!(":-moz-vframeset-border"), + PseudoElement::MozLineFrame => atom!(":-moz-line-frame"), + PseudoElement::ButtonContent => atom!(":-moz-button-content"), + PseudoElement::CellContent => atom!(":-moz-cell-content"), + PseudoElement::DropDownList => atom!(":-moz-dropdown-list"), + PseudoElement::FieldsetContent => atom!(":-moz-fieldset-content"), + PseudoElement::FramesetBlank => atom!(":-moz-frameset-blank"), + PseudoElement::MozDisplayComboboxControlFrame => atom!(":-moz-display-comboboxcontrol-frame"), + PseudoElement::HtmlCanvasContent => atom!(":-moz-html-canvas-content"), + PseudoElement::InlineTable => atom!(":-moz-inline-table"), + PseudoElement::Table => atom!(":-moz-table"), + PseudoElement::TableCell => atom!(":-moz-table-cell"), + PseudoElement::TableColGroup => atom!(":-moz-table-column-group"), + PseudoElement::TableCol => atom!(":-moz-table-column"), + PseudoElement::TableWrapper => atom!(":-moz-table-wrapper"), + PseudoElement::TableRowGroup => atom!(":-moz-table-row-group"), + PseudoElement::TableRow => atom!(":-moz-table-row"), + PseudoElement::Canvas => atom!(":-moz-canvas"), + PseudoElement::PageBreak => atom!(":-moz-pagebreak"), + PseudoElement::Page => atom!(":-moz-page"), + PseudoElement::PageContent => atom!(":-moz-pagecontent"), + PseudoElement::PageSequence => atom!(":-moz-page-sequence"), + PseudoElement::ScrolledContent => atom!(":-moz-scrolled-content"), + PseudoElement::ScrolledCanvas => atom!(":-moz-scrolled-canvas"), + PseudoElement::ScrolledPageSequence => atom!(":-moz-scrolled-page-sequence"), + PseudoElement::ColumnContent => atom!(":-moz-column-content"), + PseudoElement::Viewport => atom!(":-moz-viewport"), + PseudoElement::ViewportScroll => atom!(":-moz-viewport-scroll"), + PseudoElement::AnonymousFlexItem => atom!(":-moz-anonymous-flex-item"), + PseudoElement::AnonymousGridItem => atom!(":-moz-anonymous-grid-item"), + PseudoElement::Ruby => atom!(":-moz-ruby"), + PseudoElement::RubyBase => atom!(":-moz-ruby-base"), + PseudoElement::RubyBaseContainer => atom!(":-moz-ruby-base-container"), + PseudoElement::RubyText => atom!(":-moz-ruby-text"), + PseudoElement::RubyTextContainer => atom!(":-moz-ruby-text-container"), + PseudoElement::Moztreecolumn => atom!(":-moz-tree-column"), + PseudoElement::Moztreerow => atom!(":-moz-tree-row"), + PseudoElement::Moztreeseparator => atom!(":-moz-tree-separator"), + PseudoElement::Moztreecell => atom!(":-moz-tree-cell"), + PseudoElement::Moztreeindentation => atom!(":-moz-tree-indentation"), + PseudoElement::Moztreeline => atom!(":-moz-tree-line"), + PseudoElement::Moztreetwisty => atom!(":-moz-tree-twisty"), + PseudoElement::Moztreeimage => atom!(":-moz-tree-image"), + PseudoElement::Moztreecelltext => atom!(":-moz-tree-cell-text"), + PseudoElement::Moztreecheckbox => atom!(":-moz-tree-checkbox"), + PseudoElement::Moztreeprogressmeter => atom!(":-moz-tree-progressmeter"), + PseudoElement::Moztreedropfeedback => atom!(":-moz-tree-drop-feedback"), + PseudoElement::MozSVGMarkerAnonChild => atom!(":-moz-svg-marker-anon-child"), + PseudoElement::MozSVGOuterSVGAnonChild => atom!(":-moz-svg-outer-svg-anon-child"), + PseudoElement::MozSVGForeignContent => atom!(":-moz-svg-foreign-content"), + PseudoElement::MozSVGText => atom!(":-moz-svg-text"), + } + } + + /// Whether this pseudo-element is an anonymous box. + #[inline] + fn is_anon_box(&self) -> bool { + match *self { + PseudoElement::After => false, + PseudoElement::Before => false, + PseudoElement::Backdrop => false, + PseudoElement::Cue => false, + PseudoElement::FirstLetter => false, + PseudoElement::FirstLine => false, + PseudoElement::MozSelection => false, + PseudoElement::MozFocusInner => false, + PseudoElement::MozFocusOuter => false, + PseudoElement::MozListBullet => false, + PseudoElement::MozListNumber => false, + PseudoElement::MozMathAnonymous => false, + PseudoElement::MozNumberWrapper => false, + PseudoElement::MozNumberText => false, + PseudoElement::MozNumberSpinBox => false, + PseudoElement::MozNumberSpinUp => false, + PseudoElement::MozNumberSpinDown => false, + PseudoElement::MozProgressBar => false, + PseudoElement::MozRangeTrack => false, + PseudoElement::MozRangeProgress => false, + PseudoElement::MozRangeThumb => false, + PseudoElement::MozMeterBar => false, + PseudoElement::MozPlaceholder => false, + PseudoElement::Placeholder => false, + PseudoElement::MozColorSwatch => false, + PseudoElement::MozText => true, + PseudoElement::OofPlaceholder => true, + PseudoElement::FirstLetterContinuation => true, + PseudoElement::MozBlockInsideInlineWrapper => true, + PseudoElement::MozMathMLAnonymousBlock => true, + PseudoElement::MozXULAnonymousBlock => true, + PseudoElement::HorizontalFramesetBorder => true, + PseudoElement::VerticalFramesetBorder => true, + PseudoElement::MozLineFrame => true, + PseudoElement::ButtonContent => true, + PseudoElement::CellContent => true, + PseudoElement::DropDownList => true, + PseudoElement::FieldsetContent => true, + PseudoElement::FramesetBlank => true, + PseudoElement::MozDisplayComboboxControlFrame => true, + PseudoElement::HtmlCanvasContent => true, + PseudoElement::InlineTable => true, + PseudoElement::Table => true, + PseudoElement::TableCell => true, + PseudoElement::TableColGroup => true, + PseudoElement::TableCol => true, + PseudoElement::TableWrapper => true, + PseudoElement::TableRowGroup => true, + PseudoElement::TableRow => true, + PseudoElement::Canvas => true, + PseudoElement::PageBreak => true, + PseudoElement::Page => true, + PseudoElement::PageContent => true, + PseudoElement::PageSequence => true, + PseudoElement::ScrolledContent => true, + PseudoElement::ScrolledCanvas => true, + PseudoElement::ScrolledPageSequence => true, + PseudoElement::ColumnContent => true, + PseudoElement::Viewport => true, + PseudoElement::ViewportScroll => true, + PseudoElement::AnonymousFlexItem => true, + PseudoElement::AnonymousGridItem => true, + PseudoElement::Ruby => true, + PseudoElement::RubyBase => true, + PseudoElement::RubyBaseContainer => true, + PseudoElement::RubyText => true, + PseudoElement::RubyTextContainer => true, + PseudoElement::Moztreecolumn => true, + PseudoElement::Moztreerow => true, + PseudoElement::Moztreeseparator => true, + PseudoElement::Moztreecell => true, + PseudoElement::Moztreeindentation => true, + PseudoElement::Moztreeline => true, + PseudoElement::Moztreetwisty => true, + PseudoElement::Moztreeimage => true, + PseudoElement::Moztreecelltext => true, + PseudoElement::Moztreecheckbox => true, + PseudoElement::Moztreeprogressmeter => true, + PseudoElement::Moztreedropfeedback => true, + PseudoElement::MozSVGMarkerAnonChild => true, + PseudoElement::MozSVGOuterSVGAnonChild => true, + PseudoElement::MozSVGForeignContent => true, + PseudoElement::MozSVGText => true, + } + } + + /// Whether this pseudo-element is eagerly-cascaded. + #[inline] + pub fn is_eager(&self) -> bool { + matches!(*self, + PseudoElement::Before | PseudoElement::After) + } + + /// Whether this pseudo-element is precomputed. + #[inline] + pub fn is_precomputed(&self) -> bool { + self.is_anon_box() + } + + /// Construct a pseudo-element from a `CSSPseudoElementType`. + #[inline] + pub fn from_pseudo_type(type_: CSSPseudoElementType) -> Option<Self> { + match type_ { + CSSPseudoElementType::after => { + Some(PseudoElement::After) + }, + CSSPseudoElementType::before => { + Some(PseudoElement::Before) + }, + CSSPseudoElementType::backdrop => { + Some(PseudoElement::Backdrop) + }, + CSSPseudoElementType::cue => { + Some(PseudoElement::Cue) + }, + CSSPseudoElementType::firstLetter => { + Some(PseudoElement::FirstLetter) + }, + CSSPseudoElementType::firstLine => { + Some(PseudoElement::FirstLine) + }, + CSSPseudoElementType::mozSelection => { + Some(PseudoElement::MozSelection) + }, + CSSPseudoElementType::mozFocusInner => { + Some(PseudoElement::MozFocusInner) + }, + CSSPseudoElementType::mozFocusOuter => { + Some(PseudoElement::MozFocusOuter) + }, + CSSPseudoElementType::mozListBullet => { + Some(PseudoElement::MozListBullet) + }, + CSSPseudoElementType::mozListNumber => { + Some(PseudoElement::MozListNumber) + }, + CSSPseudoElementType::mozMathAnonymous => { + Some(PseudoElement::MozMathAnonymous) + }, + CSSPseudoElementType::mozNumberWrapper => { + Some(PseudoElement::MozNumberWrapper) + }, + CSSPseudoElementType::mozNumberText => { + Some(PseudoElement::MozNumberText) + }, + CSSPseudoElementType::mozNumberSpinBox => { + Some(PseudoElement::MozNumberSpinBox) + }, + CSSPseudoElementType::mozNumberSpinUp => { + Some(PseudoElement::MozNumberSpinUp) + }, + CSSPseudoElementType::mozNumberSpinDown => { + Some(PseudoElement::MozNumberSpinDown) + }, + CSSPseudoElementType::mozProgressBar => { + Some(PseudoElement::MozProgressBar) + }, + CSSPseudoElementType::mozRangeTrack => { + Some(PseudoElement::MozRangeTrack) + }, + CSSPseudoElementType::mozRangeProgress => { + Some(PseudoElement::MozRangeProgress) + }, + CSSPseudoElementType::mozRangeThumb => { + Some(PseudoElement::MozRangeThumb) + }, + CSSPseudoElementType::mozMeterBar => { + Some(PseudoElement::MozMeterBar) + }, + CSSPseudoElementType::mozPlaceholder => { + Some(PseudoElement::MozPlaceholder) + }, + CSSPseudoElementType::placeholder => { + Some(PseudoElement::Placeholder) + }, + CSSPseudoElementType::mozColorSwatch => { + Some(PseudoElement::MozColorSwatch) + }, + _ => None, + } + } + + /// Construct a pseudo-element from an anonymous box `Atom`. + #[inline] + pub fn from_anon_box_atom(atom: &Atom) -> Option<Self> { + if atom == &atom!(":-moz-text") { + return Some(PseudoElement::MozText); + } + if atom == &atom!(":-moz-oof-placeholder") { + return Some(PseudoElement::OofPlaceholder); + } + if atom == &atom!(":-moz-first-letter-continuation") { + return Some(PseudoElement::FirstLetterContinuation); + } + if atom == &atom!(":-moz-block-inside-inline-wrapper") { + return Some(PseudoElement::MozBlockInsideInlineWrapper); + } + if atom == &atom!(":-moz-mathml-anonymous-block") { + return Some(PseudoElement::MozMathMLAnonymousBlock); + } + if atom == &atom!(":-moz-xul-anonymous-block") { + return Some(PseudoElement::MozXULAnonymousBlock); + } + if atom == &atom!(":-moz-hframeset-border") { + return Some(PseudoElement::HorizontalFramesetBorder); + } + if atom == &atom!(":-moz-vframeset-border") { + return Some(PseudoElement::VerticalFramesetBorder); + } + if atom == &atom!(":-moz-line-frame") { + return Some(PseudoElement::MozLineFrame); + } + if atom == &atom!(":-moz-button-content") { + return Some(PseudoElement::ButtonContent); + } + if atom == &atom!(":-moz-cell-content") { + return Some(PseudoElement::CellContent); + } + if atom == &atom!(":-moz-dropdown-list") { + return Some(PseudoElement::DropDownList); + } + if atom == &atom!(":-moz-fieldset-content") { + return Some(PseudoElement::FieldsetContent); + } + if atom == &atom!(":-moz-frameset-blank") { + return Some(PseudoElement::FramesetBlank); + } + if atom == &atom!(":-moz-display-comboboxcontrol-frame") { + return Some(PseudoElement::MozDisplayComboboxControlFrame); + } + if atom == &atom!(":-moz-html-canvas-content") { + return Some(PseudoElement::HtmlCanvasContent); + } + if atom == &atom!(":-moz-inline-table") { + return Some(PseudoElement::InlineTable); + } + if atom == &atom!(":-moz-table") { + return Some(PseudoElement::Table); + } + if atom == &atom!(":-moz-table-cell") { + return Some(PseudoElement::TableCell); + } + if atom == &atom!(":-moz-table-column-group") { + return Some(PseudoElement::TableColGroup); + } + if atom == &atom!(":-moz-table-column") { + return Some(PseudoElement::TableCol); + } + if atom == &atom!(":-moz-table-wrapper") { + return Some(PseudoElement::TableWrapper); + } + if atom == &atom!(":-moz-table-row-group") { + return Some(PseudoElement::TableRowGroup); + } + if atom == &atom!(":-moz-table-row") { + return Some(PseudoElement::TableRow); + } + if atom == &atom!(":-moz-canvas") { + return Some(PseudoElement::Canvas); + } + if atom == &atom!(":-moz-pagebreak") { + return Some(PseudoElement::PageBreak); + } + if atom == &atom!(":-moz-page") { + return Some(PseudoElement::Page); + } + if atom == &atom!(":-moz-pagecontent") { + return Some(PseudoElement::PageContent); + } + if atom == &atom!(":-moz-page-sequence") { + return Some(PseudoElement::PageSequence); + } + if atom == &atom!(":-moz-scrolled-content") { + return Some(PseudoElement::ScrolledContent); + } + if atom == &atom!(":-moz-scrolled-canvas") { + return Some(PseudoElement::ScrolledCanvas); + } + if atom == &atom!(":-moz-scrolled-page-sequence") { + return Some(PseudoElement::ScrolledPageSequence); + } + if atom == &atom!(":-moz-column-content") { + return Some(PseudoElement::ColumnContent); + } + if atom == &atom!(":-moz-viewport") { + return Some(PseudoElement::Viewport); + } + if atom == &atom!(":-moz-viewport-scroll") { + return Some(PseudoElement::ViewportScroll); + } + if atom == &atom!(":-moz-anonymous-flex-item") { + return Some(PseudoElement::AnonymousFlexItem); + } + if atom == &atom!(":-moz-anonymous-grid-item") { + return Some(PseudoElement::AnonymousGridItem); + } + if atom == &atom!(":-moz-ruby") { + return Some(PseudoElement::Ruby); + } + if atom == &atom!(":-moz-ruby-base") { + return Some(PseudoElement::RubyBase); + } + if atom == &atom!(":-moz-ruby-base-container") { + return Some(PseudoElement::RubyBaseContainer); + } + if atom == &atom!(":-moz-ruby-text") { + return Some(PseudoElement::RubyText); + } + if atom == &atom!(":-moz-ruby-text-container") { + return Some(PseudoElement::RubyTextContainer); + } + if atom == &atom!(":-moz-tree-column") { + return Some(PseudoElement::Moztreecolumn); + } + if atom == &atom!(":-moz-tree-row") { + return Some(PseudoElement::Moztreerow); + } + if atom == &atom!(":-moz-tree-separator") { + return Some(PseudoElement::Moztreeseparator); + } + if atom == &atom!(":-moz-tree-cell") { + return Some(PseudoElement::Moztreecell); + } + if atom == &atom!(":-moz-tree-indentation") { + return Some(PseudoElement::Moztreeindentation); + } + if atom == &atom!(":-moz-tree-line") { + return Some(PseudoElement::Moztreeline); + } + if atom == &atom!(":-moz-tree-twisty") { + return Some(PseudoElement::Moztreetwisty); + } + if atom == &atom!(":-moz-tree-image") { + return Some(PseudoElement::Moztreeimage); + } + if atom == &atom!(":-moz-tree-cell-text") { + return Some(PseudoElement::Moztreecelltext); + } + if atom == &atom!(":-moz-tree-checkbox") { + return Some(PseudoElement::Moztreecheckbox); + } + if atom == &atom!(":-moz-tree-progressmeter") { + return Some(PseudoElement::Moztreeprogressmeter); + } + if atom == &atom!(":-moz-tree-drop-feedback") { + return Some(PseudoElement::Moztreedropfeedback); + } + if atom == &atom!(":-moz-svg-marker-anon-child") { + return Some(PseudoElement::MozSVGMarkerAnonChild); + } + if atom == &atom!(":-moz-svg-outer-svg-anon-child") { + return Some(PseudoElement::MozSVGOuterSVGAnonChild); + } + if atom == &atom!(":-moz-svg-foreign-content") { + return Some(PseudoElement::MozSVGForeignContent); + } + if atom == &atom!(":-moz-svg-text") { + return Some(PseudoElement::MozSVGText); + } + None + } + + /// Constructs an atom from a string of text, and whether we're in a + /// user-agent stylesheet. + /// + /// If we're not in a user-agent stylesheet, we will never parse anonymous + /// box pseudo-elements. + /// + /// Returns `None` if the pseudo-element is not recognised. + #[inline] + pub fn from_slice(s: &str, in_ua_stylesheet: bool) -> Option<Self> { + use std::ascii::AsciiExt; + + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("after") { + return Some(PseudoElement::After) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("before") { + return Some(PseudoElement::Before) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("backdrop") { + return Some(PseudoElement::Backdrop) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("cue") { + return Some(PseudoElement::Cue) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("first-letter") { + return Some(PseudoElement::FirstLetter) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("first-line") { + return Some(PseudoElement::FirstLine) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-selection") { + return Some(PseudoElement::MozSelection) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-focus-inner") { + return Some(PseudoElement::MozFocusInner) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-focus-outer") { + return Some(PseudoElement::MozFocusOuter) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-list-bullet") { + return Some(PseudoElement::MozListBullet) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-list-number") { + return Some(PseudoElement::MozListNumber) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-math-anonymous") { + return Some(PseudoElement::MozMathAnonymous) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-number-wrapper") { + return Some(PseudoElement::MozNumberWrapper) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-number-text") { + return Some(PseudoElement::MozNumberText) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-number-spin-box") { + return Some(PseudoElement::MozNumberSpinBox) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-number-spin-up") { + return Some(PseudoElement::MozNumberSpinUp) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-number-spin-down") { + return Some(PseudoElement::MozNumberSpinDown) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-progress-bar") { + return Some(PseudoElement::MozProgressBar) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-range-track") { + return Some(PseudoElement::MozRangeTrack) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-range-progress") { + return Some(PseudoElement::MozRangeProgress) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-range-thumb") { + return Some(PseudoElement::MozRangeThumb) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-meter-bar") { + return Some(PseudoElement::MozMeterBar) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-placeholder") { + return Some(PseudoElement::MozPlaceholder) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("placeholder") { + return Some(PseudoElement::Placeholder) + } + } + if !false || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-color-swatch") { + return Some(PseudoElement::MozColorSwatch) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-text") { + return Some(PseudoElement::MozText) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-oof-placeholder") { + return Some(PseudoElement::OofPlaceholder) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-first-letter-continuation") { + return Some(PseudoElement::FirstLetterContinuation) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-block-inside-inline-wrapper") { + return Some(PseudoElement::MozBlockInsideInlineWrapper) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-mathml-anonymous-block") { + return Some(PseudoElement::MozMathMLAnonymousBlock) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-xul-anonymous-block") { + return Some(PseudoElement::MozXULAnonymousBlock) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-hframeset-border") { + return Some(PseudoElement::HorizontalFramesetBorder) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-vframeset-border") { + return Some(PseudoElement::VerticalFramesetBorder) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-line-frame") { + return Some(PseudoElement::MozLineFrame) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-button-content") { + return Some(PseudoElement::ButtonContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-cell-content") { + return Some(PseudoElement::CellContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-dropdown-list") { + return Some(PseudoElement::DropDownList) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-fieldset-content") { + return Some(PseudoElement::FieldsetContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-frameset-blank") { + return Some(PseudoElement::FramesetBlank) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-display-comboboxcontrol-frame") { + return Some(PseudoElement::MozDisplayComboboxControlFrame) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-html-canvas-content") { + return Some(PseudoElement::HtmlCanvasContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-inline-table") { + return Some(PseudoElement::InlineTable) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table") { + return Some(PseudoElement::Table) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-cell") { + return Some(PseudoElement::TableCell) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-column-group") { + return Some(PseudoElement::TableColGroup) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-column") { + return Some(PseudoElement::TableCol) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-wrapper") { + return Some(PseudoElement::TableWrapper) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-row-group") { + return Some(PseudoElement::TableRowGroup) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-table-row") { + return Some(PseudoElement::TableRow) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-canvas") { + return Some(PseudoElement::Canvas) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-pagebreak") { + return Some(PseudoElement::PageBreak) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-page") { + return Some(PseudoElement::Page) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-pagecontent") { + return Some(PseudoElement::PageContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-page-sequence") { + return Some(PseudoElement::PageSequence) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-scrolled-content") { + return Some(PseudoElement::ScrolledContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-scrolled-canvas") { + return Some(PseudoElement::ScrolledCanvas) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-scrolled-page-sequence") { + return Some(PseudoElement::ScrolledPageSequence) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-column-content") { + return Some(PseudoElement::ColumnContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-viewport") { + return Some(PseudoElement::Viewport) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-viewport-scroll") { + return Some(PseudoElement::ViewportScroll) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-anonymous-flex-item") { + return Some(PseudoElement::AnonymousFlexItem) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-anonymous-grid-item") { + return Some(PseudoElement::AnonymousGridItem) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-ruby") { + return Some(PseudoElement::Ruby) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-ruby-base") { + return Some(PseudoElement::RubyBase) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-ruby-base-container") { + return Some(PseudoElement::RubyBaseContainer) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-ruby-text") { + return Some(PseudoElement::RubyText) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-ruby-text-container") { + return Some(PseudoElement::RubyTextContainer) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-column") { + return Some(PseudoElement::Moztreecolumn) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-row") { + return Some(PseudoElement::Moztreerow) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-separator") { + return Some(PseudoElement::Moztreeseparator) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-cell") { + return Some(PseudoElement::Moztreecell) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-indentation") { + return Some(PseudoElement::Moztreeindentation) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-line") { + return Some(PseudoElement::Moztreeline) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-twisty") { + return Some(PseudoElement::Moztreetwisty) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-image") { + return Some(PseudoElement::Moztreeimage) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-cell-text") { + return Some(PseudoElement::Moztreecelltext) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-checkbox") { + return Some(PseudoElement::Moztreecheckbox) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-progressmeter") { + return Some(PseudoElement::Moztreeprogressmeter) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-tree-drop-feedback") { + return Some(PseudoElement::Moztreedropfeedback) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-svg-marker-anon-child") { + return Some(PseudoElement::MozSVGMarkerAnonChild) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-svg-outer-svg-anon-child") { + return Some(PseudoElement::MozSVGOuterSVGAnonChild) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-svg-foreign-content") { + return Some(PseudoElement::MozSVGForeignContent) + } + } + if !true || in_ua_stylesheet { + if s.eq_ignore_ascii_case("-moz-svg-text") { + return Some(PseudoElement::MozSVGText) + } + } + + None + } + + /// Returns the pseudo-element's definition as a string, with only one colon + /// before it. + pub fn as_str(&self) -> &'static str { + match *self { + PseudoElement::After => ":after", + PseudoElement::Before => ":before", + PseudoElement::Backdrop => ":backdrop", + PseudoElement::Cue => ":cue", + PseudoElement::FirstLetter => ":first-letter", + PseudoElement::FirstLine => ":first-line", + PseudoElement::MozSelection => ":-moz-selection", + PseudoElement::MozFocusInner => ":-moz-focus-inner", + PseudoElement::MozFocusOuter => ":-moz-focus-outer", + PseudoElement::MozListBullet => ":-moz-list-bullet", + PseudoElement::MozListNumber => ":-moz-list-number", + PseudoElement::MozMathAnonymous => ":-moz-math-anonymous", + PseudoElement::MozNumberWrapper => ":-moz-number-wrapper", + PseudoElement::MozNumberText => ":-moz-number-text", + PseudoElement::MozNumberSpinBox => ":-moz-number-spin-box", + PseudoElement::MozNumberSpinUp => ":-moz-number-spin-up", + PseudoElement::MozNumberSpinDown => ":-moz-number-spin-down", + PseudoElement::MozProgressBar => ":-moz-progress-bar", + PseudoElement::MozRangeTrack => ":-moz-range-track", + PseudoElement::MozRangeProgress => ":-moz-range-progress", + PseudoElement::MozRangeThumb => ":-moz-range-thumb", + PseudoElement::MozMeterBar => ":-moz-meter-bar", + PseudoElement::MozPlaceholder => ":-moz-placeholder", + PseudoElement::Placeholder => ":placeholder", + PseudoElement::MozColorSwatch => ":-moz-color-swatch", + PseudoElement::MozText => ":-moz-text", + PseudoElement::OofPlaceholder => ":-moz-oof-placeholder", + PseudoElement::FirstLetterContinuation => ":-moz-first-letter-continuation", + PseudoElement::MozBlockInsideInlineWrapper => ":-moz-block-inside-inline-wrapper", + PseudoElement::MozMathMLAnonymousBlock => ":-moz-mathml-anonymous-block", + PseudoElement::MozXULAnonymousBlock => ":-moz-xul-anonymous-block", + PseudoElement::HorizontalFramesetBorder => ":-moz-hframeset-border", + PseudoElement::VerticalFramesetBorder => ":-moz-vframeset-border", + PseudoElement::MozLineFrame => ":-moz-line-frame", + PseudoElement::ButtonContent => ":-moz-button-content", + PseudoElement::CellContent => ":-moz-cell-content", + PseudoElement::DropDownList => ":-moz-dropdown-list", + PseudoElement::FieldsetContent => ":-moz-fieldset-content", + PseudoElement::FramesetBlank => ":-moz-frameset-blank", + PseudoElement::MozDisplayComboboxControlFrame => ":-moz-display-comboboxcontrol-frame", + PseudoElement::HtmlCanvasContent => ":-moz-html-canvas-content", + PseudoElement::InlineTable => ":-moz-inline-table", + PseudoElement::Table => ":-moz-table", + PseudoElement::TableCell => ":-moz-table-cell", + PseudoElement::TableColGroup => ":-moz-table-column-group", + PseudoElement::TableCol => ":-moz-table-column", + PseudoElement::TableWrapper => ":-moz-table-wrapper", + PseudoElement::TableRowGroup => ":-moz-table-row-group", + PseudoElement::TableRow => ":-moz-table-row", + PseudoElement::Canvas => ":-moz-canvas", + PseudoElement::PageBreak => ":-moz-pagebreak", + PseudoElement::Page => ":-moz-page", + PseudoElement::PageContent => ":-moz-pagecontent", + PseudoElement::PageSequence => ":-moz-page-sequence", + PseudoElement::ScrolledContent => ":-moz-scrolled-content", + PseudoElement::ScrolledCanvas => ":-moz-scrolled-canvas", + PseudoElement::ScrolledPageSequence => ":-moz-scrolled-page-sequence", + PseudoElement::ColumnContent => ":-moz-column-content", + PseudoElement::Viewport => ":-moz-viewport", + PseudoElement::ViewportScroll => ":-moz-viewport-scroll", + PseudoElement::AnonymousFlexItem => ":-moz-anonymous-flex-item", + PseudoElement::AnonymousGridItem => ":-moz-anonymous-grid-item", + PseudoElement::Ruby => ":-moz-ruby", + PseudoElement::RubyBase => ":-moz-ruby-base", + PseudoElement::RubyBaseContainer => ":-moz-ruby-base-container", + PseudoElement::RubyText => ":-moz-ruby-text", + PseudoElement::RubyTextContainer => ":-moz-ruby-text-container", + PseudoElement::Moztreecolumn => ":-moz-tree-column", + PseudoElement::Moztreerow => ":-moz-tree-row", + PseudoElement::Moztreeseparator => ":-moz-tree-separator", + PseudoElement::Moztreecell => ":-moz-tree-cell", + PseudoElement::Moztreeindentation => ":-moz-tree-indentation", + PseudoElement::Moztreeline => ":-moz-tree-line", + PseudoElement::Moztreetwisty => ":-moz-tree-twisty", + PseudoElement::Moztreeimage => ":-moz-tree-image", + PseudoElement::Moztreecelltext => ":-moz-tree-cell-text", + PseudoElement::Moztreecheckbox => ":-moz-tree-checkbox", + PseudoElement::Moztreeprogressmeter => ":-moz-tree-progressmeter", + PseudoElement::Moztreedropfeedback => ":-moz-tree-drop-feedback", + PseudoElement::MozSVGMarkerAnonChild => ":-moz-svg-marker-anon-child", + PseudoElement::MozSVGOuterSVGAnonChild => ":-moz-svg-outer-svg-anon-child", + PseudoElement::MozSVGForeignContent => ":-moz-svg-foreign-content", + PseudoElement::MozSVGText => ":-moz-svg-text", + } + } +} diff --git a/components/style/gecko/generated/pseudo_element_helper.rs b/components/style/gecko/generated/pseudo_element_helper.rs deleted file mode 100644 index e9d61b03bd8..00000000000 --- a/components/style/gecko/generated/pseudo_element_helper.rs +++ /dev/null @@ -1,280 +0,0 @@ -/* This Source Code Form is subject to the terms of the Mozilla Public - * 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/. */ - -/* Autogenerated file created by components/style/binding_tools/regen_atoms.py, DO NOT EDIT DIRECTLY */ - -/* - * This file contains a helper macro invocation to aid Gecko's style system - * pseudo-element integration. - * - * This file is NOT INTENDED to be compiled as a standalone module. - * - * Also, it guarantees the property that normal pseudo-elements are processed - * before anonymous boxes. - * - * Expected usage is as follows: - * - * ``` - * fn have_to_use_pseudo_elements() { - * macro_rules! pseudo_element { - * ($pseudo_str_with_colon:expr, $pseudo_atom:expr, $is_anon_box:true) => {{ - * // Stuff stuff stuff. - * }} - * } - * include!("path/to/helper.rs") - * } - * ``` - * - */ -{ - pseudo_element!(":after", - atom!(":after"), - false); - pseudo_element!(":before", - atom!(":before"), - false); - pseudo_element!(":backdrop", - atom!(":backdrop"), - false); - pseudo_element!(":cue", - atom!(":cue"), - false); - pseudo_element!(":first-letter", - atom!(":first-letter"), - false); - pseudo_element!(":first-line", - atom!(":first-line"), - false); - pseudo_element!(":-moz-selection", - atom!(":-moz-selection"), - false); - pseudo_element!(":-moz-focus-inner", - atom!(":-moz-focus-inner"), - false); - pseudo_element!(":-moz-focus-outer", - atom!(":-moz-focus-outer"), - false); - pseudo_element!(":-moz-list-bullet", - atom!(":-moz-list-bullet"), - false); - pseudo_element!(":-moz-list-number", - atom!(":-moz-list-number"), - false); - pseudo_element!(":-moz-math-anonymous", - atom!(":-moz-math-anonymous"), - false); - pseudo_element!(":-moz-number-wrapper", - atom!(":-moz-number-wrapper"), - false); - pseudo_element!(":-moz-number-text", - atom!(":-moz-number-text"), - false); - pseudo_element!(":-moz-number-spin-box", - atom!(":-moz-number-spin-box"), - false); - pseudo_element!(":-moz-number-spin-up", - atom!(":-moz-number-spin-up"), - false); - pseudo_element!(":-moz-number-spin-down", - atom!(":-moz-number-spin-down"), - false); - pseudo_element!(":-moz-progress-bar", - atom!(":-moz-progress-bar"), - false); - pseudo_element!(":-moz-range-track", - atom!(":-moz-range-track"), - false); - pseudo_element!(":-moz-range-progress", - atom!(":-moz-range-progress"), - false); - pseudo_element!(":-moz-range-thumb", - atom!(":-moz-range-thumb"), - false); - pseudo_element!(":-moz-meter-bar", - atom!(":-moz-meter-bar"), - false); - pseudo_element!(":-moz-placeholder", - atom!(":-moz-placeholder"), - false); - pseudo_element!(":placeholder", - atom!(":placeholder"), - false); - pseudo_element!(":-moz-color-swatch", - atom!(":-moz-color-swatch"), - false); - pseudo_element!(":-moz-text", - atom!(":-moz-text"), - true); - pseudo_element!(":-moz-oof-placeholder", - atom!(":-moz-oof-placeholder"), - true); - pseudo_element!(":-moz-first-letter-continuation", - atom!(":-moz-first-letter-continuation"), - true); - pseudo_element!(":-moz-block-inside-inline-wrapper", - atom!(":-moz-block-inside-inline-wrapper"), - true); - pseudo_element!(":-moz-mathml-anonymous-block", - atom!(":-moz-mathml-anonymous-block"), - true); - pseudo_element!(":-moz-xul-anonymous-block", - atom!(":-moz-xul-anonymous-block"), - true); - pseudo_element!(":-moz-hframeset-border", - atom!(":-moz-hframeset-border"), - true); - pseudo_element!(":-moz-vframeset-border", - atom!(":-moz-vframeset-border"), - true); - pseudo_element!(":-moz-line-frame", - atom!(":-moz-line-frame"), - true); - pseudo_element!(":-moz-button-content", - atom!(":-moz-button-content"), - true); - pseudo_element!(":-moz-cell-content", - atom!(":-moz-cell-content"), - true); - pseudo_element!(":-moz-dropdown-list", - atom!(":-moz-dropdown-list"), - true); - pseudo_element!(":-moz-fieldset-content", - atom!(":-moz-fieldset-content"), - true); - pseudo_element!(":-moz-frameset-blank", - atom!(":-moz-frameset-blank"), - true); - pseudo_element!(":-moz-display-comboboxcontrol-frame", - atom!(":-moz-display-comboboxcontrol-frame"), - true); - pseudo_element!(":-moz-html-canvas-content", - atom!(":-moz-html-canvas-content"), - true); - pseudo_element!(":-moz-inline-table", - atom!(":-moz-inline-table"), - true); - pseudo_element!(":-moz-table", - atom!(":-moz-table"), - true); - pseudo_element!(":-moz-table-cell", - atom!(":-moz-table-cell"), - true); - pseudo_element!(":-moz-table-column-group", - atom!(":-moz-table-column-group"), - true); - pseudo_element!(":-moz-table-column", - atom!(":-moz-table-column"), - true); - pseudo_element!(":-moz-table-wrapper", - atom!(":-moz-table-wrapper"), - true); - pseudo_element!(":-moz-table-row-group", - atom!(":-moz-table-row-group"), - true); - pseudo_element!(":-moz-table-row", - atom!(":-moz-table-row"), - true); - pseudo_element!(":-moz-canvas", - atom!(":-moz-canvas"), - true); - pseudo_element!(":-moz-pagebreak", - atom!(":-moz-pagebreak"), - true); - pseudo_element!(":-moz-page", - atom!(":-moz-page"), - true); - pseudo_element!(":-moz-pagecontent", - atom!(":-moz-pagecontent"), - true); - pseudo_element!(":-moz-page-sequence", - atom!(":-moz-page-sequence"), - true); - pseudo_element!(":-moz-scrolled-content", - atom!(":-moz-scrolled-content"), - true); - pseudo_element!(":-moz-scrolled-canvas", - atom!(":-moz-scrolled-canvas"), - true); - pseudo_element!(":-moz-scrolled-page-sequence", - atom!(":-moz-scrolled-page-sequence"), - true); - pseudo_element!(":-moz-column-content", - atom!(":-moz-column-content"), - true); - pseudo_element!(":-moz-viewport", - atom!(":-moz-viewport"), - true); - pseudo_element!(":-moz-viewport-scroll", - atom!(":-moz-viewport-scroll"), - true); - pseudo_element!(":-moz-anonymous-flex-item", - atom!(":-moz-anonymous-flex-item"), - true); - pseudo_element!(":-moz-anonymous-grid-item", - atom!(":-moz-anonymous-grid-item"), - true); - pseudo_element!(":-moz-ruby", - atom!(":-moz-ruby"), - true); - pseudo_element!(":-moz-ruby-base", - atom!(":-moz-ruby-base"), - true); - pseudo_element!(":-moz-ruby-base-container", - atom!(":-moz-ruby-base-container"), - true); - pseudo_element!(":-moz-ruby-text", - atom!(":-moz-ruby-text"), - true); - pseudo_element!(":-moz-ruby-text-container", - atom!(":-moz-ruby-text-container"), - true); - pseudo_element!(":-moz-tree-column", - atom!(":-moz-tree-column"), - true); - pseudo_element!(":-moz-tree-row", - atom!(":-moz-tree-row"), - true); - pseudo_element!(":-moz-tree-separator", - atom!(":-moz-tree-separator"), - true); - pseudo_element!(":-moz-tree-cell", - atom!(":-moz-tree-cell"), - true); - pseudo_element!(":-moz-tree-indentation", - atom!(":-moz-tree-indentation"), - true); - pseudo_element!(":-moz-tree-line", - atom!(":-moz-tree-line"), - true); - pseudo_element!(":-moz-tree-twisty", - atom!(":-moz-tree-twisty"), - true); - pseudo_element!(":-moz-tree-image", - atom!(":-moz-tree-image"), - true); - pseudo_element!(":-moz-tree-cell-text", - atom!(":-moz-tree-cell-text"), - true); - pseudo_element!(":-moz-tree-checkbox", - atom!(":-moz-tree-checkbox"), - true); - pseudo_element!(":-moz-tree-progressmeter", - atom!(":-moz-tree-progressmeter"), - true); - pseudo_element!(":-moz-tree-drop-feedback", - atom!(":-moz-tree-drop-feedback"), - true); - pseudo_element!(":-moz-svg-marker-anon-child", - atom!(":-moz-svg-marker-anon-child"), - true); - pseudo_element!(":-moz-svg-outer-svg-anon-child", - atom!(":-moz-svg-outer-svg-anon-child"), - true); - pseudo_element!(":-moz-svg-foreign-content", - atom!(":-moz-svg-foreign-content"), - true); - pseudo_element!(":-moz-svg-text", - atom!(":-moz-svg-text"), - true); -} diff --git a/components/style/gecko/generated/structs_debug.rs b/components/style/gecko/generated/structs_debug.rs index dd2114a1f06..3141fa27c16 100644 --- a/components/style/gecko/generated/structs_debug.rs +++ b/components/style/gecko/generated/structs_debug.rs @@ -974,6 +974,7 @@ pub mod root { pub const NS_STYLE_DISPLAY_MODE_BROWSER: ::std::os::raw::c_uint = 0; pub const NS_STYLE_DISPLAY_MODE_MINIMAL_UI: ::std::os::raw::c_uint = 1; pub const NS_STYLE_DISPLAY_MODE_STANDALONE: ::std::os::raw::c_uint = 2; + pub const NS_STYLE_DISPLAY_MODE_FULLSCREEN: ::std::os::raw::c_uint = 3; pub const NS_THEME_NONE: ::std::os::raw::c_uint = 0; pub const NS_THEME_BUTTON: ::std::os::raw::c_uint = 1; pub const NS_THEME_RADIO: ::std::os::raw::c_uint = 2; @@ -1168,6 +1169,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 { @@ -1197,10 +1200,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>>, @@ -1218,7 +1228,7 @@ pub mod root { pub struct atomic { } #[test] - fn __bindgen_test_layout_atomic_instantiation_89651() { + fn __bindgen_test_layout_atomic_instantiation_61468() { assert_eq!(::std::mem::size_of::<u32>() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -1227,7 +1237,7 @@ pub mod root { ( u32 ) )); } #[test] - fn __bindgen_test_layout_atomic_instantiation_89659() { + fn __bindgen_test_layout_atomic_instantiation_61476() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -1288,8 +1298,9 @@ pub mod root { root::nsSubstringTuple; pub type nsStringRepr_string_type = ::nsstring::nsStringRepr; pub type nsStringRepr_const_iterator = - root::nsReadingIterator<u16>; - pub type nsStringRepr_iterator = root::nsWritingIterator<u16>; + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>; + pub type nsStringRepr_iterator = + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>; pub type nsStringRepr_comparator_type = root::nsStringComparator; pub type nsStringRepr_char_iterator = *mut root::mozilla::detail::nsStringRepr_char_type; @@ -1379,9 +1390,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<root::mozilla::detail::nsCStringRepr_char_type>; pub type nsCStringRepr_iterator = - root::nsWritingIterator<::std::os::raw::c_char>; + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>; pub type nsCStringRepr_comparator_type = root::nsCStringComparator; pub type nsCStringRepr_char_iterator = @@ -1456,11 +1467,6 @@ pub mod root { impl Clone for nsCStringRepr { fn clone(&self) -> Self { *self } } - #[repr(C)] - #[derive(Debug, Copy, Clone)] - pub struct AllocPolicyBasedFreePolicy { - pub _address: u8, - } /** * LinkedList supports refcounted elements using this adapter class. Clients * using LinkedList<RefPtr<T>> will get a data structure that holds a strong @@ -1896,7 +1902,7 @@ pub mod root { pub struct ImageValue { pub _base: root::mozilla::css::URLValueData, pub mRequests: [u64; 6usize], - pub mInitialized: bool, + pub mLoadedImage: bool, } #[test] fn bindgen_test_layout_ImageValue() { @@ -1912,10 +1918,10 @@ pub mod root { "Alignment of field: " , stringify ! ( ImageValue ) , "::" , stringify ! ( mRequests ) )); assert_eq! (unsafe { - & ( * ( 0 as * const ImageValue ) ) . mInitialized + & ( * ( 0 as * const ImageValue ) ) . mLoadedImage as * const _ as usize } , 104usize , concat ! ( "Alignment of field: " , stringify ! ( ImageValue - ) , "::" , stringify ! ( mInitialized ) )); + ) , "::" , stringify ! ( mLoadedImage ) )); } #[repr(C)] #[derive(Debug)] @@ -6883,7 +6889,7 @@ pub mod root { _unused: [u8; 0], } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_141274() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_118151() { assert_eq!(::std::mem::size_of::<root::mozilla::StaticRefPtr<root::mozilla::URLExtraData>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -8022,7 +8028,7 @@ pub mod root { #[repr(C)] #[derive(Debug)] pub struct ImageCacheKey { - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mBlobSerial: [u64; 2usize], pub mOriginAttributes: root::mozilla::OriginAttributes, pub mControlledDocument: *mut ::std::os::raw::c_void, @@ -9096,8 +9102,10 @@ pub mod root { PropertyStyleAnimationValuePair ) , "::" , stringify ! ( mValue ) )); } + pub type ComputedKeyframeValues = + root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>; #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_178529() { + fn __bindgen_test_layout_DefaultDelete_instantiation_155856() { assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -11412,22 +11420,6 @@ pub mod root { "Alignment of " , stringify ! ( nsCString ) )); } #[repr(C)] - #[derive(Debug)] - pub struct nsDependentCSubstring { - pub _base: root::nsACString, - } - pub type nsDependentCSubstring_self_type = root::nsDependentCSubstring; - #[test] - fn bindgen_test_layout_nsDependentCSubstring() { - assert_eq!(::std::mem::size_of::<nsDependentCSubstring>() , 16usize , - concat ! ( - "Size of: " , stringify ! ( nsDependentCSubstring ) )); - assert_eq! (::std::mem::align_of::<nsDependentCSubstring>() , 8usize , - concat ! ( - "Alignment of " , stringify ! ( nsDependentCSubstring ) - )); - } - #[repr(C)] pub struct nsCStringComparator__bindgen_vtable(::std::os::raw::c_void); #[repr(C)] #[derive(Debug, Copy)] @@ -11552,7 +11544,7 @@ pub mod root { pub _address: u8, } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_55035() { + fn __bindgen_test_layout_nsCharTraits_instantiation_51312() { assert_eq!(::std::mem::size_of::<root::nsCharTraits>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -11563,7 +11555,7 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_55039() { + fn __bindgen_test_layout_nsCharTraits_instantiation_51316() { assert_eq!(::std::mem::size_of::<root::nsCharTraits>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -12483,26 +12475,6 @@ pub mod root { pub type MutableHandleValue = root::JS::MutableHandle<root::JS::Value>; pub type RootedObject = [u64; 3usize]; - #[repr(C)] - #[derive(Debug, Copy, Clone)] - pub struct DeletePolicy { - pub _address: u8, - } - #[repr(C)] - #[derive(Debug, Copy)] - pub struct FreePolicy { - pub _address: u8, - } - #[test] - fn bindgen_test_layout_FreePolicy() { - assert_eq!(::std::mem::size_of::<FreePolicy>() , 1usize , concat ! - ( "Size of: " , stringify ! ( FreePolicy ) )); - assert_eq! (::std::mem::align_of::<FreePolicy>() , 1usize , concat - ! ( "Alignment of " , stringify ! ( FreePolicy ) )); - } - impl Clone for FreePolicy { - fn clone(&self) -> Self { *self } - } /** * A GC pointer, tagged with the trace kind. * @@ -12810,6 +12782,11 @@ pub mod root { AutoSetAsyncStackForNewCalls ) , "::" , stringify ! ( oldAsyncCallIsExplicit ) )); } + pub type WarningReporter = + ::std::option::Option<unsafe extern "C" fn(cx: + *mut root::JSContext, + report: + *mut root::JSErrorReport)>; #[repr(C)] #[derive(Debug)] pub struct AutoHideScriptedCaller { @@ -12971,6 +12948,96 @@ 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<root::JSErrorNotes>, + 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::<JSErrorReport>() , 72usize , concat ! + ( "Size of: " , stringify ! ( JSErrorReport ) )); + assert_eq! (::std::mem::align_of::<JSErrorReport>() , 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 mask = 1usize as u8; + let field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + let val = (field_val & mask) >> 0usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_isMuted(&mut self, val: bool) { + let mask = 1usize as u8; + let val = val as u8 as u8; + let mut field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + field_val &= !mask; + field_val |= (val << 0usize) & mask; + self._bitfield_1 = unsafe { ::std::mem::transmute(field_val) }; + } + #[inline] + pub fn ownsLinebuf_(&self) -> bool { + let mask = 2usize as u8; + let field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + let val = (field_val & mask) >> 1usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_ownsLinebuf_(&mut self, val: bool) { + let mask = 2usize as u8; + let val = val as u8 as u8; + let mut field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + field_val &= !mask; + field_val |= (val << 1usize) & mask; + self._bitfield_1 = unsafe { ::std::mem::transmute(field_val) }; + } + } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct JSRuntime { @@ -13036,7 +13103,7 @@ pub mod root { } pub type nsCOMPtr_element_type<T> = T; #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_92866() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_64757() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsISupports>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -13784,7 +13851,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<u32>, } #[test] fn bindgen_test_layout_gfxFontFeatureValueSet_ValueList() { @@ -13889,7 +13956,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<u32>, } pub type gfxFontFeatureValueSet_FeatureValueHashEntry_KeyType = *const root::gfxFontFeatureValueSet_FeatureValueHashKey; @@ -13999,7 +14066,7 @@ pub mod root { pub alternateValues: root::nsTArray<root::gfxAlternateValue>, pub featureValueLookup: root::RefPtr<root::gfxFontFeatureValueSet>, pub fontFeatureSettings: root::nsTArray<root::gfxFontFeature>, - pub fontVariationSettings: root::nsTArray<root::mozilla::gfx::FontVariation>, + pub fontVariationSettings: root::nsTArray<root::gfxFontVariation>, pub languageOverride: u32, } #[test] @@ -16399,7 +16466,7 @@ pub mod root { */ pub mFrameRequestCallbackCounter: i32, pub mStaticCloneCount: u32, - pub mBlockedTrackingNodes: root::nsTArray<root::nsCOMPtr<root::nsIWeakReference>>, + pub mBlockedTrackingNodes: root::nsTArray<root::nsWeakPtr>, pub mWindow: *mut root::nsPIDOMWindowInner, pub mCachedEncoder: root::nsCOMPtr<root::nsIDocumentEncoder>, pub mFrameRequestCallbacks: root::nsTArray<root::nsIDocument_FrameRequest>, @@ -19686,7 +19753,7 @@ pub mod root { pub _base_1: root::nsWrapperCache, pub mRefCnt: root::nsCycleCollectingAutoRefCnt, pub _mOwningThread: root::nsAutoOwningThread, - pub mContent: root::nsCOMPtr<root::mozilla::dom::Element>, + pub mContent: root::nsCOMPtr<root::nsDOMAttributeMap_Element>, /** * Cache of Attrs. */ @@ -20719,57 +20786,57 @@ pub mod root { pub struct nsDOMMutationObserver { _unused: [u8; 0], } - pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_LISTENERMANAGER; - pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_PROPERTIES; - pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_ANONYMOUS_ROOT; - pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; - pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_NATIVE_ANONYMOUS_ROOT; - pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_FORCE_XBL_BINDINGS; - pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_MAY_BE_IN_BINDING_MNGR; - pub const NODE_IS_EDITABLE: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_EDITABLE; - pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_NATIVE_ANONYMOUS; - pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_IN_SHADOW_TREE; - pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_EMPTY_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_SLOW_SELECTOR; - pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_EDGE_CHILD_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; - pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_ALL_SELECTOR_FLAGS; - pub const NODE_NEEDS_FRAME: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_NEEDS_FRAME; - pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_DESCENDANTS_NEED_FRAMES; - pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_ACCESSKEY; - pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_DIRECTION_RTL; - pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_HAS_DIRECTION_LTR; - pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_ALL_DIRECTION_FLAGS; - pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_CHROME_ONLY_ACCESS; - pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; - pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_84 = - _bindgen_ty_84::NODE_TYPE_SPECIFIC_BITS_OFFSET; + pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_LISTENERMANAGER; + pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_PROPERTIES; + pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_ANONYMOUS_ROOT; + pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; + pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_NATIVE_ANONYMOUS_ROOT; + pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_FORCE_XBL_BINDINGS; + pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_MAY_BE_IN_BINDING_MNGR; + pub const NODE_IS_EDITABLE: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_EDITABLE; + pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_NATIVE_ANONYMOUS; + pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_IN_SHADOW_TREE; + pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_EMPTY_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_SLOW_SELECTOR; + pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_EDGE_CHILD_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; + pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_ALL_SELECTOR_FLAGS; + pub const NODE_NEEDS_FRAME: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_NEEDS_FRAME; + pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_DESCENDANTS_NEED_FRAMES; + pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_ACCESSKEY; + pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_DIRECTION_RTL; + pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_HAS_DIRECTION_LTR; + pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_ALL_DIRECTION_FLAGS; + pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_CHROME_ONLY_ACCESS; + pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; + pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_77 = + _bindgen_ty_77::NODE_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_84 { + pub enum _bindgen_ty_77 { NODE_HAS_LISTENERMANAGER = 4, NODE_HAS_PROPERTIES = 8, NODE_IS_ANONYMOUS_ROOT = 16, @@ -25922,7 +25989,7 @@ pub mod root { pub mRefCnt: root::nsAutoRefCnt, pub _mOwningThread: root::nsAutoOwningThread, pub mBehaviour: root::mozilla::UniquePtr<root::ProxyBehaviour>, - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mListener: *mut root::imgINotificationObserver, pub mLoadGroup: root::nsCOMPtr<root::nsILoadGroup>, pub mLoadFlags: root::nsLoadFlags, @@ -27154,7 +27221,7 @@ pub mod root { pub _mOwningThread: root::nsAutoOwningThread, pub mLoader: *mut root::imgLoader, pub mRequest: root::nsCOMPtr<root::nsIRequest>, - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mCurrentURI: root::nsCOMPtr<root::nsIURI>, pub mLoadingPrincipal: root::nsCOMPtr<root::nsIPrincipal>, pub mPrincipal: root::nsCOMPtr<root::nsIPrincipal>, @@ -27181,8 +27248,8 @@ pub mod root { pub mImageErrorCode: root::nsresult, pub mBoostCategoriesRequested: u32, pub mMutex: root::mozilla::Mutex, - pub mProgressTracker: root::RefPtr<root::mozilla::image::ProgressTracker>, - pub mImage: root::RefPtr<root::mozilla::image::Image>, + pub mProgressTracker: root::RefPtr<root::imgRequest_ProgressTracker>, + pub mImage: root::RefPtr<root::imgRequest_Image>, pub _bitfield_1: u8, pub __bindgen_padding_0: [u8; 7usize], } @@ -28612,7 +28679,7 @@ pub mod root { ) , "::" , stringify ! ( mQuotePairs ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_174521() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_151848() { assert_eq!(::std::mem::size_of::<root::mozilla::StaticRefPtr<root::nsStyleQuoteValues>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -30711,7 +30778,7 @@ pub mod root { pub type RawGeckoURLExtraData = root::mozilla::URLExtraData; pub type RawGeckoKeyframeList = root::nsTArray<root::mozilla::Keyframe>; pub type RawGeckoComputedKeyframeValuesList = - root::nsTArray<root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>>; + root::nsTArray<root::mozilla::ComputedKeyframeValues>; pub type RawGeckoAnimationValueList = root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>; pub type RawGeckoStyleAnimationList = @@ -31074,48 +31141,48 @@ pub mod root { pub struct nsAttrValueOrString { _unused: [u8; 0], } - pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_86 = - _bindgen_ty_86::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_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_86 + 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_86::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_86 = - _bindgen_ty_86::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; - pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_PENDING_RESTYLE_FLAGS; - pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; - pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_ALL_RESTYLE_FLAGS; - pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_86 = - _bindgen_ty_86::ELEMENT_HAS_SCROLLGRAB; - pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_86 = - _bindgen_ty_86::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_86 { + pub enum _bindgen_ty_79 { ELEMENT_SHARED_RESTYLE_BIT_1 = 8388608, ELEMENT_SHARED_RESTYLE_BIT_2 = 16777216, ELEMENT_SHARED_RESTYLE_BIT_3 = 33554432, @@ -31836,7 +31903,7 @@ pub mod root { } pub type __builtin_va_list = [root::__va_list_tag; 1usize]; #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_202097() { + fn __bindgen_test_layout_IntegralConstant_instantiation_179636() { assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -31845,7 +31912,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_202101() { + fn __bindgen_test_layout_IntegralConstant_instantiation_179640() { assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -31854,69 +31921,59 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_202928() { - assert_eq!(::std::mem::size_of::<root::nsReadingIterator<u16>>() , - 24usize , concat ! ( + fn __bindgen_test_layout_nsReadingIterator_instantiation_180472() { + assert_eq!(::std::mem::size_of::<root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<u16> ) )); - assert_eq!(::std::mem::align_of::<root::nsReadingIterator<u16>>() , - 8usize , concat ! ( + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<u16> ) )); + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_202932() { - assert_eq!(::std::mem::size_of::<root::nsWritingIterator<u16>>() , - 24usize , concat ! ( + fn __bindgen_test_layout_nsWritingIterator_instantiation_180475() { + assert_eq!(::std::mem::size_of::<root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<u16> ) )); - assert_eq!(::std::mem::align_of::<root::nsWritingIterator<u16>>() , - 8usize , concat ! ( + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<u16> ) )); + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_203005() { - assert_eq!(::std::mem::size_of::<root::nsReadingIterator<::std::os::raw::c_char>>() + fn __bindgen_test_layout_nsReadingIterator_instantiation_180547() { + assert_eq!(::std::mem::size_of::<root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::<root::nsReadingIterator<::std::os::raw::c_char>>() + root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); + root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_203009() { - assert_eq!(::std::mem::size_of::<root::nsWritingIterator<::std::os::raw::c_char>>() + fn __bindgen_test_layout_nsWritingIterator_instantiation_180550() { + assert_eq!(::std::mem::size_of::<root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::<root::nsWritingIterator<::std::os::raw::c_char>>() + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - } - #[test] - fn __bindgen_test_layout__bindgen_ty_id_208835_instantiation_208832() { - assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( u8 ) - )); - assert_eq!(::std::mem::align_of::<u8>() , 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( u8 + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type> ) )); } #[test] - fn __bindgen_test_layout__bindgen_ty_id_208868_instantiation_208865() { - assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( u8 ) - )); - assert_eq!(::std::mem::align_of::<u8>() , 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( u8 - ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_209136() { + fn __bindgen_test_layout_nsTArray_instantiation_184957() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCString>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31927,7 +31984,7 @@ pub mod root { root::nsTArray<root::nsCString> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_210095() { + fn __bindgen_test_layout_Handle_instantiation_185808() { assert_eq!(::std::mem::size_of::<root::JS::Handle<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31938,7 +31995,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_210111() { + fn __bindgen_test_layout_Handle_instantiation_185824() { assert_eq!(::std::mem::size_of::<root::JS::Handle<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31949,7 +32006,7 @@ pub mod root { root::JS::Handle<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_210121() { + fn __bindgen_test_layout_MutableHandle_instantiation_185834() { assert_eq!(::std::mem::size_of::<root::JS::MutableHandle<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31960,7 +32017,7 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_210137() { + fn __bindgen_test_layout_MutableHandle_instantiation_185850() { assert_eq!(::std::mem::size_of::<root::JS::MutableHandle<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31971,7 +32028,7 @@ pub mod root { root::JS::MutableHandle<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_210140() { + fn __bindgen_test_layout_Rooted_instantiation_185853() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31982,18 +32039,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_210477() { - assert_eq!(::std::mem::size_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_212527() { + fn __bindgen_test_layout_nsTArray_instantiation_188400() { assert_eq!(::std::mem::size_of::<root::nsTArray<::nsstring::nsStringRepr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32004,7 +32050,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_212531() { + fn __bindgen_test_layout_nsTArray_instantiation_188404() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::FontFamilyName>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32015,18 +32061,18 @@ pub mod root { root::nsTArray<root::mozilla::FontFamilyName> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_212544() { - assert_eq!(::std::mem::size_of::<root::nsTArray<::std::os::raw::c_uint>>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_188417() { + assert_eq!(::std::mem::size_of::<root::nsTArray<u32>>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::<root::nsTArray<::std::os::raw::c_uint>>() - , 8usize , concat ! ( + root::nsTArray<u32> ) )); + assert_eq!(::std::mem::align_of::<root::nsTArray<u32>>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray<u32> ) )); } #[test] - fn __bindgen_test_layout_TenuredHeap_instantiation_213669() { + fn __bindgen_test_layout_TenuredHeap_instantiation_189579() { assert_eq!(::std::mem::size_of::<root::JS::TenuredHeap>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32037,7 +32083,7 @@ pub mod root { root::JS::TenuredHeap ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_213759() { + fn __bindgen_test_layout_Heap_instantiation_189669() { assert_eq!(::std::mem::size_of::<root::JS::Heap<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32048,7 +32094,7 @@ pub mod root { root::JS::Heap<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_213874() { + fn __bindgen_test_layout_Heap_instantiation_189784() { assert_eq!(::std::mem::size_of::<root::JS::Heap<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32059,7 +32105,7 @@ pub mod root { root::JS::Heap<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_213881() { + fn __bindgen_test_layout_TErrorResult_instantiation_189791() { assert_eq!(::std::mem::size_of::<root::mozilla::binding_danger::TErrorResult>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32070,7 +32116,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_213897() { + fn __bindgen_test_layout_TErrorResult_instantiation_189807() { assert_eq!(::std::mem::size_of::<root::mozilla::binding_danger::TErrorResult>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32081,7 +32127,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_213902() { + fn __bindgen_test_layout_already_AddRefed_instantiation_189812() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsStringBuffer>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32092,7 +32138,7 @@ pub mod root { root::already_AddRefed<root::nsStringBuffer> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_213954() { + fn __bindgen_test_layout_already_AddRefed_instantiation_189864() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIAtom>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32103,7 +32149,7 @@ pub mod root { root::already_AddRefed<root::nsIAtom> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_214437() { + fn __bindgen_test_layout_RefPtr_instantiation_190347() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::StyleSheet>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32114,7 +32160,7 @@ pub mod root { root::RefPtr<root::mozilla::StyleSheet> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_214783() { + fn __bindgen_test_layout_already_AddRefed_instantiation_190693() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::dom::NodeInfo>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32125,7 +32171,7 @@ pub mod root { root::already_AddRefed<root::mozilla::dom::NodeInfo> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_215028() { + fn __bindgen_test_layout_already_AddRefed_instantiation_190938() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIURI>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32136,7 +32182,7 @@ pub mod root { root::already_AddRefed<root::nsIURI> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_215175() { + fn __bindgen_test_layout_already_AddRefed_instantiation_191085() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsINode>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32147,18 +32193,7 @@ pub mod root { root::already_AddRefed<root::nsINode> ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_219294() { - assert_eq!(::std::mem::size_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_219292() { + fn __bindgen_test_layout_UniquePtr_instantiation_195189() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::JSErrorNotes_Note>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32169,7 +32204,7 @@ pub mod root { root::mozilla::UniquePtr<root::JSErrorNotes_Note> ) )); } #[test] - fn __bindgen_test_layout_iterator_instantiation_219327() { + fn __bindgen_test_layout_iterator_instantiation_195221() { assert_eq!(::std::mem::size_of::<root::std::iterator>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32180,7 +32215,7 @@ pub mod root { root::std::iterator ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_219895() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_195790() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsIPrincipal>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32191,7 +32226,7 @@ pub mod root { root::nsCOMPtr<root::nsIPrincipal> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_221493() { + fn __bindgen_test_layout_nsTArray_instantiation_197378() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::AnonymousContent>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32204,7 +32239,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_LinkedList_instantiation_221769() { + fn __bindgen_test_layout_LinkedList_instantiation_197651() { assert_eq!(::std::mem::size_of::<root::mozilla::LinkedList>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32215,7 +32250,7 @@ pub mod root { root::mozilla::LinkedList ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_221785() { + fn __bindgen_test_layout_RefPtr_instantiation_197667() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::Element>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32226,7 +32261,7 @@ pub mod root { root::RefPtr<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_221784() { + fn __bindgen_test_layout_nsTArray_instantiation_197666() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::Element>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32239,7 +32274,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_221814() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_197696() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsIObserver>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32250,7 +32285,7 @@ pub mod root { root::nsCOMPtr<root::nsIObserver> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_221813() { + fn __bindgen_test_layout_nsTArray_instantiation_197695() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCOMPtr<root::nsIObserver>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32261,7 +32296,7 @@ pub mod root { root::nsTArray<root::nsCOMPtr<root::nsIObserver>> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_221859() { + fn __bindgen_test_layout_already_AddRefed_instantiation_197741() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIDocument>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32272,7 +32307,7 @@ pub mod root { root::already_AddRefed<root::nsIDocument> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_222024() { + fn __bindgen_test_layout_already_AddRefed_instantiation_197906() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsContentList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32283,7 +32318,7 @@ pub mod root { root::already_AddRefed<root::nsContentList> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_222351() { + fn __bindgen_test_layout_already_AddRefed_instantiation_198233() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIRunnable>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32294,7 +32329,7 @@ pub mod root { root::already_AddRefed<root::nsIRunnable> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_222444() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_198326() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::mozilla::dom::Link>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32305,29 +32340,7 @@ pub mod root { root::nsCOMPtr<root::mozilla::dom::Link> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_222481() { - assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsIWeakReference>>() - , 8usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr<root::nsIWeakReference> ) )); - assert_eq!(::std::mem::align_of::<root::nsCOMPtr<root::nsIWeakReference>>() - , 8usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr<root::nsIWeakReference> ) )); - } - #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_222739() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_222737() { + fn __bindgen_test_layout_UniquePtr_instantiation_198617() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsISMILAttr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32338,7 +32351,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsISMILAttr> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_223287() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_199164() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::mozilla::dom::DOMIntersectionObserver>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32351,7 +32364,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_223286() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_199163() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32362,7 +32375,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_223403() { + fn __bindgen_test_layout_nsTArray_instantiation_199279() { assert_eq!(::std::mem::size_of::<root::nsTArray<*mut root::nsIContent>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32373,7 +32386,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_223454() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_199330() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -32382,7 +32395,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_223634() { + fn __bindgen_test_layout_nsTArray_instantiation_199510() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32393,18 +32406,7 @@ pub mod root { root::nsTArray<root::nsRect> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_223750() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_223915() { + fn __bindgen_test_layout_nsTArray_instantiation_199788() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCOMPtr<root::nsIAtom>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32415,7 +32417,7 @@ pub mod root { root::nsTArray<root::nsCOMPtr<root::nsIAtom>> ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_224702() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_200575() { assert_eq!(::std::mem::size_of::<[u64; 29usize]>() , 232usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32426,7 +32428,7 @@ pub mod root { [u64; 29usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_224794() { + fn __bindgen_test_layout_already_AddRefed_instantiation_200667() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIContent>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32437,7 +32439,7 @@ pub mod root { root::already_AddRefed<root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_224975() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_200848() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32448,7 +32450,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_225498() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_201371() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<::std::os::raw::c_void>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32459,7 +32461,7 @@ pub mod root { root::nsPtrHashKey<::std::os::raw::c_void> ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_225506() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_201379() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::WeakFrame>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32470,7 +32472,7 @@ pub mod root { root::nsPtrHashKey<root::WeakFrame> ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_225621() { + fn __bindgen_test_layout_OwningNonNull_instantiation_201494() { assert_eq!(::std::mem::size_of::<root::mozilla::OwningNonNull<root::nsINode>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32481,7 +32483,18 @@ pub mod root { root::mozilla::OwningNonNull<root::nsINode> ) )); } #[test] - fn __bindgen_test_layout_PointTyped_instantiation_226700() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_201621() { + assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsIWeakReference>>() + , 8usize , concat ! ( + "Size of template specialization: " , stringify ! ( + root::nsCOMPtr<root::nsIWeakReference> ) )); + assert_eq!(::std::mem::align_of::<root::nsCOMPtr<root::nsIWeakReference>>() + , 8usize , concat ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCOMPtr<root::nsIWeakReference> ) )); + } + #[test] + fn __bindgen_test_layout_PointTyped_instantiation_202573() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32492,7 +32505,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_226705() { + fn __bindgen_test_layout_IntPointTyped_instantiation_202576() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32503,7 +32516,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SizeTyped_instantiation_226708() { + fn __bindgen_test_layout_SizeTyped_instantiation_202579() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32514,7 +32527,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_226716() { + fn __bindgen_test_layout_RectTyped_instantiation_202585() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32525,7 +32538,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_226748() { + fn __bindgen_test_layout_IntPointTyped_instantiation_202609() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32536,7 +32549,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntSizeTyped_instantiation_226756() { + fn __bindgen_test_layout_IntSizeTyped_instantiation_202615() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32547,7 +32560,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_226764() { + fn __bindgen_test_layout_IntRectTyped_instantiation_202621() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32558,7 +32571,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_MarginTyped_instantiation_226931() { + fn __bindgen_test_layout_MarginTyped_instantiation_202750() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32569,7 +32582,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_226966() { + fn __bindgen_test_layout_RectTyped_instantiation_202777() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32580,7 +32593,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_226971() { + fn __bindgen_test_layout_IntRectTyped_instantiation_202780() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32591,7 +32604,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactor_instantiation_227017() { + fn __bindgen_test_layout_ScaleFactor_instantiation_202816() { assert_eq!(::std::mem::size_of::<u32>() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -32600,7 +32613,7 @@ pub mod root { u32 ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_227117() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_202916() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32611,7 +32624,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_227125() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_202924() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32622,7 +32635,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_227169() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_202968() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32633,7 +32646,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_227799() { + fn __bindgen_test_layout_nsTArray_instantiation_203598() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::FramePropertyTable_PropertyValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32646,7 +32659,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_227815() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_203614() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::nsIFrame>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32657,7 +32670,7 @@ pub mod root { root::nsPtrHashKey<root::nsIFrame> ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_231089() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_206877() { assert_eq!(::std::mem::size_of::<[u64; 29usize]>() , 232usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32668,7 +32681,7 @@ pub mod root { [u64; 29usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_231725() { + fn __bindgen_test_layout_already_AddRefed_instantiation_207510() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::dom::CSSValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32679,18 +32692,7 @@ pub mod root { root::already_AddRefed<root::mozilla::dom::CSSValue> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_231816() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_231820() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_207602() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32701,7 +32703,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_233009() { + fn __bindgen_test_layout_already_AddRefed_instantiation_208791() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsISupports>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32712,7 +32714,7 @@ pub mod root { root::already_AddRefed<root::nsISupports> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_233295() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_209137() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr<root::nsIRunnable>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32723,7 +32725,7 @@ pub mod root { root::nsCOMPtr<root::nsIRunnable> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_234885() { + fn __bindgen_test_layout_nsTArray_instantiation_210717() { assert_eq!(::std::mem::size_of::<root::nsTArray<f64>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32734,7 +32736,7 @@ pub mod root { root::nsTArray<f64> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_234897() { + fn __bindgen_test_layout_RefPtr_instantiation_210729() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::DOMIntersectionObserverEntry>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32747,7 +32749,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_234896() { + fn __bindgen_test_layout_nsTArray_instantiation_210728() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::DOMIntersectionObserverEntry>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32760,7 +32762,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_234930() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_210762() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::mozilla::dom::Element>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32771,7 +32773,7 @@ pub mod root { root::nsPtrHashKey<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_235027() { + fn __bindgen_test_layout_UniquePtr_instantiation_210859() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::ProfilerBacktrace>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32782,7 +32784,7 @@ pub mod root { root::mozilla::UniquePtr<root::ProfilerBacktrace> ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_236809() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_212630() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32793,7 +32795,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_236848() { + fn __bindgen_test_layout_OwningNonNull_instantiation_212669() { assert_eq!(::std::mem::size_of::<root::mozilla::OwningNonNull<root::mozilla::EffectCompositor_AnimationStyleRuleProcessor>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32806,7 +32808,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_236869() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_212690() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::nsIAtom>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32817,7 +32819,7 @@ pub mod root { root::nsRefPtrHashKey<root::nsIAtom> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_236900() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_212721() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::nsIContent>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32828,18 +32830,7 @@ pub mod root { root::nsRefPtrHashKey<root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_237445() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_237459() { + fn __bindgen_test_layout_already_AddRefed_instantiation_213277() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::URLExtraData>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32850,7 +32841,7 @@ pub mod root { root::already_AddRefed<root::mozilla::URLExtraData> ) )); } #[test] - fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_237463() { + fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_213281() { assert_eq!(::std::mem::size_of::<root::nsMainThreadPtrHolder<root::nsIURI>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32861,7 +32852,7 @@ pub mod root { root::nsMainThreadPtrHolder<root::nsIURI> ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_237537() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_213355() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::nsIDocument>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32872,18 +32863,7 @@ pub mod root { root::nsPtrHashKey<root::nsIDocument> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_237824() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_237822() { + fn __bindgen_test_layout_UniquePtr_instantiation_213640() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsCSSValueList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32894,18 +32874,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsCSSValueList> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_237830() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_237828() { + fn __bindgen_test_layout_UniquePtr_instantiation_213643() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsCSSValuePairList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32916,7 +32885,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsCSSValuePairList> ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_238173() { + fn __bindgen_test_layout_Maybe_instantiation_213985() { assert_eq!(::std::mem::size_of::<[u64; 2usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32927,7 +32896,7 @@ pub mod root { [u64; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_238340() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_214151() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -32936,7 +32905,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_238491() { + fn __bindgen_test_layout_Maybe_instantiation_214304() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32947,7 +32916,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_238506() { + fn __bindgen_test_layout_already_AddRefed_instantiation_214319() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsStyleImageRequest>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32958,18 +32927,7 @@ pub mod root { root::already_AddRefed<root::nsStyleImageRequest> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_238514() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_238512() { + fn __bindgen_test_layout_UniquePtr_instantiation_214325() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsStyleSides>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32980,18 +32938,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsStyleSides> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_238553() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_pair_instantiation_238704() { + fn __bindgen_test_layout_pair_instantiation_214511() { assert_eq!(::std::mem::size_of::<root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr>>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33002,7 +32949,7 @@ pub mod root { root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_238703() { + fn __bindgen_test_layout_nsTArray_instantiation_214510() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr>>>() , 8usize , concat ! ( @@ -33017,7 +32964,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_239705() { + fn __bindgen_test_layout_RefPtr_instantiation_215512() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::RawServoAnimationValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33028,7 +32975,7 @@ pub mod root { root::RefPtr<root::RawServoAnimationValue> ) )); } #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_243697() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_219500() { assert_eq!(::std::mem::size_of::<root::mozilla::BaseTimeDuration>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33039,7 +32986,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_244289() { + fn __bindgen_test_layout_nsTArray_instantiation_220092() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::DisplayItemClip_RoundedRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33052,7 +32999,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_244471() { + fn __bindgen_test_layout_Maybe_instantiation_220272() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33063,7 +33010,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_244646() { + fn __bindgen_test_layout_RefPtr_instantiation_220447() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::DOMRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33074,7 +33021,7 @@ pub mod root { root::RefPtr<root::mozilla::dom::DOMRect> ) )); } #[test] - fn __bindgen_test_layout_Sequence_instantiation_244890() { + fn __bindgen_test_layout_Sequence_instantiation_220691() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -33083,7 +33030,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_245189() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_220990() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::mozilla::dom::Element>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33094,7 +33041,7 @@ pub mod root { root::nsRefPtrHashKey<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_nsClassHashtable_instantiation_245188() { + fn __bindgen_test_layout_nsClassHashtable_instantiation_220989() { assert_eq!(::std::mem::size_of::<[u64; 6usize]>() , 48usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33105,7 +33052,7 @@ pub mod root { [u64; 6usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_246324() { + fn __bindgen_test_layout_nsTArray_instantiation_222132() { assert_eq!(::std::mem::size_of::<root::nsTArray<*mut root::mozilla::css::DocumentRule>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -33116,7 +33063,7 @@ pub mod root { root::nsTArray<*mut root::mozilla::css::DocumentRule> ) )); } #[test] - fn __bindgen_test_layout_nsAutoPtr_instantiation_246362() { + fn __bindgen_test_layout_nsAutoPtr_instantiation_222170() { assert_eq!(::std::mem::size_of::<root::nsAutoPtr<root::nsMediaQuery>>() , 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 6c30b5bcdce..b1aa9e383de 100644 --- a/components/style/gecko/generated/structs_release.rs +++ b/components/style/gecko/generated/structs_release.rs @@ -974,6 +974,7 @@ pub mod root { pub const NS_STYLE_DISPLAY_MODE_BROWSER: ::std::os::raw::c_uint = 0; pub const NS_STYLE_DISPLAY_MODE_MINIMAL_UI: ::std::os::raw::c_uint = 1; pub const NS_STYLE_DISPLAY_MODE_STANDALONE: ::std::os::raw::c_uint = 2; + pub const NS_STYLE_DISPLAY_MODE_FULLSCREEN: ::std::os::raw::c_uint = 3; pub const NS_THEME_NONE: ::std::os::raw::c_uint = 0; pub const NS_THEME_BUTTON: ::std::os::raw::c_uint = 1; pub const NS_THEME_RADIO: ::std::os::raw::c_uint = 2; @@ -1168,6 +1169,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 { @@ -1197,10 +1200,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>>, @@ -1218,7 +1228,7 @@ pub mod root { pub struct atomic { } #[test] - fn __bindgen_test_layout_atomic_instantiation_88535() { + fn __bindgen_test_layout_atomic_instantiation_60317() { assert_eq!(::std::mem::size_of::<u32>() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -1227,7 +1237,7 @@ pub mod root { ( u32 ) )); } #[test] - fn __bindgen_test_layout_atomic_instantiation_88543() { + fn __bindgen_test_layout_atomic_instantiation_60325() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -1282,8 +1292,9 @@ pub mod root { root::nsSubstringTuple; pub type nsStringRepr_string_type = ::nsstring::nsStringRepr; pub type nsStringRepr_const_iterator = - root::nsReadingIterator<u16>; - pub type nsStringRepr_iterator = root::nsWritingIterator<u16>; + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>; + pub type nsStringRepr_iterator = + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>; pub type nsStringRepr_comparator_type = root::nsStringComparator; pub type nsStringRepr_char_iterator = *mut root::mozilla::detail::nsStringRepr_char_type; @@ -1373,9 +1384,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<root::mozilla::detail::nsCStringRepr_char_type>; pub type nsCStringRepr_iterator = - root::nsWritingIterator<::std::os::raw::c_char>; + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>; pub type nsCStringRepr_comparator_type = root::nsCStringComparator; pub type nsCStringRepr_char_iterator = @@ -1819,10 +1830,11 @@ pub mod root { pub struct ImageValue { pub _base: root::mozilla::css::URLValueData, pub mRequests: [u64; 5usize], + pub mLoadedImage: bool, } #[test] fn bindgen_test_layout_ImageValue() { - assert_eq!(::std::mem::size_of::<ImageValue>() , 96usize , + assert_eq!(::std::mem::size_of::<ImageValue>() , 104usize , concat ! ( "Size of: " , stringify ! ( ImageValue ) )); assert_eq! (::std::mem::align_of::<ImageValue>() , 8usize , @@ -1833,6 +1845,11 @@ pub mod root { * const _ as usize } , 56usize , concat ! ( "Alignment of field: " , stringify ! ( ImageValue ) , "::" , stringify ! ( mRequests ) )); + assert_eq! (unsafe { + & ( * ( 0 as * const ImageValue ) ) . mLoadedImage + as * const _ as usize } , 96usize , concat ! ( + "Alignment of field: " , stringify ! ( ImageValue + ) , "::" , stringify ! ( mLoadedImage ) )); } #[repr(C)] #[derive(Debug)] @@ -6337,24 +6354,6 @@ pub mod root { } #[repr(C)] #[derive(Debug, Copy)] - pub struct MallocAllocPolicy { - pub _address: u8, - } - #[test] - fn bindgen_test_layout_MallocAllocPolicy() { - assert_eq!(::std::mem::size_of::<MallocAllocPolicy>() , 1usize , - concat ! ( - "Size of: " , stringify ! ( MallocAllocPolicy ) )); - assert_eq! (::std::mem::align_of::<MallocAllocPolicy>() , 1usize , - concat ! ( - "Alignment of " , stringify ! ( MallocAllocPolicy ) - )); - } - impl Clone for MallocAllocPolicy { - fn clone(&self) -> Self { *self } - } - #[repr(C)] - #[derive(Debug, Copy)] pub struct ErrorResult { pub _bindgen_opaque_blob: [u64; 2usize], } @@ -6748,7 +6747,7 @@ pub mod root { _unused: [u8; 0], } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_138166() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_114814() { assert_eq!(::std::mem::size_of::<root::mozilla::StaticRefPtr<root::mozilla::URLExtraData>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -7777,7 +7776,7 @@ pub mod root { #[repr(C)] #[derive(Debug)] pub struct ImageCacheKey { - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mBlobSerial: [u64; 2usize], pub mOriginAttributes: root::mozilla::OriginAttributes, pub mControlledDocument: *mut ::std::os::raw::c_void, @@ -8851,8 +8850,10 @@ pub mod root { PropertyStyleAnimationValuePair ) , "::" , stringify ! ( mValue ) )); } + pub type ComputedKeyframeValues = + root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>; #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_175037() { + fn __bindgen_test_layout_DefaultDelete_instantiation_152177() { assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -10945,22 +10946,6 @@ pub mod root { "Alignment of " , stringify ! ( nsCString ) )); } #[repr(C)] - #[derive(Debug)] - pub struct nsDependentCSubstring { - pub _base: root::nsACString, - } - pub type nsDependentCSubstring_self_type = root::nsDependentCSubstring; - #[test] - fn bindgen_test_layout_nsDependentCSubstring() { - assert_eq!(::std::mem::size_of::<nsDependentCSubstring>() , 16usize , - concat ! ( - "Size of: " , stringify ! ( nsDependentCSubstring ) )); - assert_eq! (::std::mem::align_of::<nsDependentCSubstring>() , 8usize , - concat ! ( - "Alignment of " , stringify ! ( nsDependentCSubstring ) - )); - } - #[repr(C)] pub struct nsCStringComparator__bindgen_vtable(::std::os::raw::c_void); #[repr(C)] #[derive(Debug, Copy)] @@ -11085,7 +11070,7 @@ pub mod root { pub _address: u8, } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_53827() { + fn __bindgen_test_layout_nsCharTraits_instantiation_50051() { assert_eq!(::std::mem::size_of::<root::nsCharTraits>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -11096,7 +11081,7 @@ pub mod root { root::nsCharTraits ) )); } #[test] - fn __bindgen_test_layout_nsCharTraits_instantiation_53831() { + fn __bindgen_test_layout_nsCharTraits_instantiation_50055() { assert_eq!(::std::mem::size_of::<root::nsCharTraits>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -12004,26 +11989,6 @@ pub mod root { pub type MutableHandleValue = root::JS::MutableHandle<root::JS::Value>; pub type RootedObject = [u64; 3usize]; - #[repr(C)] - #[derive(Debug, Copy, Clone)] - pub struct DeletePolicy { - pub _address: u8, - } - #[repr(C)] - #[derive(Debug, Copy)] - pub struct FreePolicy { - pub _address: u8, - } - #[test] - fn bindgen_test_layout_FreePolicy() { - assert_eq!(::std::mem::size_of::<FreePolicy>() , 1usize , concat ! - ( "Size of: " , stringify ! ( FreePolicy ) )); - assert_eq! (::std::mem::align_of::<FreePolicy>() , 1usize , concat - ! ( "Alignment of " , stringify ! ( FreePolicy ) )); - } - impl Clone for FreePolicy { - fn clone(&self) -> Self { *self } - } /** * A GC pointer, tagged with the trace kind. * @@ -12331,6 +12296,11 @@ pub mod root { AutoSetAsyncStackForNewCalls ) , "::" , stringify ! ( oldAsyncCallIsExplicit ) )); } + pub type WarningReporter = + ::std::option::Option<unsafe extern "C" fn(cx: + *mut root::JSContext, + report: + *mut root::JSErrorReport)>; #[repr(C)] #[derive(Debug)] pub struct AutoHideScriptedCaller { @@ -12484,6 +12454,96 @@ 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<root::JSErrorNotes>, + 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::<JSErrorReport>() , 72usize , concat ! + ( "Size of: " , stringify ! ( JSErrorReport ) )); + assert_eq! (::std::mem::align_of::<JSErrorReport>() , 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 mask = 1usize as u8; + let field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + let val = (field_val & mask) >> 0usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_isMuted(&mut self, val: bool) { + let mask = 1usize as u8; + let val = val as u8 as u8; + let mut field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + field_val &= !mask; + field_val |= (val << 0usize) & mask; + self._bitfield_1 = unsafe { ::std::mem::transmute(field_val) }; + } + #[inline] + pub fn ownsLinebuf_(&self) -> bool { + let mask = 2usize as u8; + let field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + let val = (field_val & mask) >> 1usize; + unsafe { ::std::mem::transmute(val as u8) } + } + #[inline] + pub fn set_ownsLinebuf_(&mut self, val: bool) { + let mask = 2usize as u8; + let val = val as u8 as u8; + let mut field_val: u8 = + unsafe { ::std::mem::transmute(self._bitfield_1) }; + field_val &= !mask; + field_val |= (val << 1usize) & mask; + self._bitfield_1 = unsafe { ::std::mem::transmute(field_val) }; + } + } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct JSRuntime { @@ -12733,7 +12793,7 @@ pub mod root { } pub type nsCOMPtr_element_type<T> = T; #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_91623() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_63481() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -13449,7 +13509,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<u32>, } #[test] fn bindgen_test_layout_gfxFontFeatureValueSet_ValueList() { @@ -13554,7 +13614,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<u32>, } pub type gfxFontFeatureValueSet_FeatureValueHashEntry_KeyType = *const root::gfxFontFeatureValueSet_FeatureValueHashKey; @@ -13657,7 +13717,7 @@ pub mod root { pub alternateValues: root::nsTArray<root::gfxAlternateValue>, pub featureValueLookup: root::RefPtr<root::gfxFontFeatureValueSet>, pub fontFeatureSettings: root::nsTArray<root::gfxFontFeature>, - pub fontVariationSettings: root::nsTArray<root::mozilla::gfx::FontVariation>, + pub fontVariationSettings: root::nsTArray<root::gfxFontVariation>, pub languageOverride: u32, } #[test] @@ -16030,7 +16090,7 @@ pub mod root { */ pub mFrameRequestCallbackCounter: i32, pub mStaticCloneCount: u32, - pub mBlockedTrackingNodes: root::nsTArray<root::nsCOMPtr>, + pub mBlockedTrackingNodes: root::nsTArray<root::nsWeakPtr>, pub mWindow: *mut root::nsPIDOMWindowInner, pub mCachedEncoder: root::nsCOMPtr, pub mFrameRequestCallbacks: root::nsTArray<root::nsIDocument_FrameRequest>, @@ -20297,57 +20357,57 @@ pub mod root { pub struct nsDOMMutationObserver { _unused: [u8; 0], } - pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_LISTENERMANAGER; - pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_PROPERTIES; - pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_ANONYMOUS_ROOT; - pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; - pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_NATIVE_ANONYMOUS_ROOT; - pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_FORCE_XBL_BINDINGS; - pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_MAY_BE_IN_BINDING_MNGR; - pub const NODE_IS_EDITABLE: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_EDITABLE; - pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_NATIVE_ANONYMOUS; - pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_IN_SHADOW_TREE; - pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_EMPTY_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_SLOW_SELECTOR; - pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_EDGE_CHILD_SELECTOR; - pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; - pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_ALL_SELECTOR_FLAGS; - pub const NODE_NEEDS_FRAME: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_NEEDS_FRAME; - pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_DESCENDANTS_NEED_FRAMES; - pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_ACCESSKEY; - pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_DIRECTION_RTL; - pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_HAS_DIRECTION_LTR; - pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_ALL_DIRECTION_FLAGS; - pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_CHROME_ONLY_ACCESS; - pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; - pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_82 = - _bindgen_ty_82::NODE_TYPE_SPECIFIC_BITS_OFFSET; + pub const NODE_HAS_LISTENERMANAGER: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_LISTENERMANAGER; + pub const NODE_HAS_PROPERTIES: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_PROPERTIES; + pub const NODE_IS_ANONYMOUS_ROOT: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_ANONYMOUS_ROOT; + pub const NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE; + pub const NODE_IS_NATIVE_ANONYMOUS_ROOT: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_NATIVE_ANONYMOUS_ROOT; + pub const NODE_FORCE_XBL_BINDINGS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_FORCE_XBL_BINDINGS; + pub const NODE_MAY_BE_IN_BINDING_MNGR: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_MAY_BE_IN_BINDING_MNGR; + pub const NODE_IS_EDITABLE: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_EDITABLE; + pub const NODE_IS_NATIVE_ANONYMOUS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_NATIVE_ANONYMOUS; + pub const NODE_IS_IN_SHADOW_TREE: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_IN_SHADOW_TREE; + pub const NODE_HAS_EMPTY_SELECTOR: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_EMPTY_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_SLOW_SELECTOR; + pub const NODE_HAS_EDGE_CHILD_SELECTOR: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_EDGE_CHILD_SELECTOR; + pub const NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS; + pub const NODE_ALL_SELECTOR_FLAGS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_ALL_SELECTOR_FLAGS; + pub const NODE_NEEDS_FRAME: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_NEEDS_FRAME; + pub const NODE_DESCENDANTS_NEED_FRAMES: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_DESCENDANTS_NEED_FRAMES; + pub const NODE_HAS_ACCESSKEY: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_ACCESSKEY; + pub const NODE_HAS_DIRECTION_RTL: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_DIRECTION_RTL; + pub const NODE_HAS_DIRECTION_LTR: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_HAS_DIRECTION_LTR; + pub const NODE_ALL_DIRECTION_FLAGS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_ALL_DIRECTION_FLAGS; + pub const NODE_CHROME_ONLY_ACCESS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_CHROME_ONLY_ACCESS; + pub const NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_IS_ROOT_OF_CHROME_ONLY_ACCESS; + pub const NODE_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_72 = + _bindgen_ty_72::NODE_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_82 { + pub enum _bindgen_ty_72 { NODE_HAS_LISTENERMANAGER = 4, NODE_HAS_PROPERTIES = 8, NODE_IS_ANONYMOUS_ROOT = 16, @@ -25498,7 +25558,7 @@ pub mod root { pub _base_4: root::nsITimedChannel, pub mRefCnt: root::nsAutoRefCnt, pub mBehaviour: root::mozilla::UniquePtr<root::ProxyBehaviour>, - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mListener: *mut root::imgINotificationObserver, pub mLoadGroup: root::nsCOMPtr, pub mLoadFlags: root::nsLoadFlags, @@ -26638,7 +26698,7 @@ pub mod root { pub mRefCnt: root::mozilla::ThreadSafeAutoRefCnt, pub mLoader: *mut root::imgLoader, pub mRequest: root::nsCOMPtr, - pub mURI: root::RefPtr<root::mozilla::image::ImageURL>, + pub mURI: root::RefPtr<root::imgRequestProxy_ImageURL>, pub mCurrentURI: root::nsCOMPtr, pub mLoadingPrincipal: root::nsCOMPtr, pub mPrincipal: root::nsCOMPtr, @@ -26665,8 +26725,8 @@ pub mod root { pub mImageErrorCode: root::nsresult, pub mBoostCategoriesRequested: u32, pub mMutex: root::mozilla::Mutex, - pub mProgressTracker: root::RefPtr<root::mozilla::image::ProgressTracker>, - pub mImage: root::RefPtr<root::mozilla::image::Image>, + pub mProgressTracker: root::RefPtr<root::imgRequest_ProgressTracker>, + pub mImage: root::RefPtr<root::imgRequest_Image>, pub _bitfield_1: u8, pub __bindgen_padding_0: [u8; 7usize], } @@ -28096,7 +28156,7 @@ pub mod root { ) , "::" , stringify ! ( mQuotePairs ) )); } #[test] - fn __bindgen_test_layout_StaticRefPtr_instantiation_171029() { + fn __bindgen_test_layout_StaticRefPtr_instantiation_148169() { assert_eq!(::std::mem::size_of::<root::mozilla::StaticRefPtr<root::nsStyleQuoteValues>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -30195,7 +30255,7 @@ pub mod root { pub type RawGeckoURLExtraData = root::mozilla::URLExtraData; pub type RawGeckoKeyframeList = root::nsTArray<root::mozilla::Keyframe>; pub type RawGeckoComputedKeyframeValuesList = - root::nsTArray<root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>>; + root::nsTArray<root::mozilla::ComputedKeyframeValues>; pub type RawGeckoAnimationValueList = root::nsTArray<root::mozilla::PropertyStyleAnimationValuePair>; pub type RawGeckoStyleAnimationList = @@ -30558,48 +30618,48 @@ pub mod root { pub struct nsAttrValueOrString { _unused: [u8; 0], } - pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_1: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_SHARED_RESTYLE_BIT_2: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_SHARED_RESTYLE_BIT_3: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_SHARED_RESTYLE_BIT_4: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_DIRTY_DESCENDANTS_FOR_SERVO: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_1; pub const ELEMENT_HAS_ANIMATION_ONLY_DIRTY_DESCENDANTS_FOR_SERVO: - root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_3; - pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_1; - pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_2; - pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_84 + root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_SNAPSHOT: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_3; + pub const ELEMENT_HANDLED_SNAPSHOT: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_HAS_PENDING_RESTYLE: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_1; + pub const ELEMENT_IS_POTENTIAL_RESTYLE_ROOT: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_2; + pub const ELEMENT_HAS_PENDING_ANIMATION_ONLY_RESTYLE: root::_bindgen_ty_74 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_3; + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_3; pub const ELEMENT_IS_POTENTIAL_ANIMATION_ONLY_RESTYLE_ROOT: - root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_SHARED_RESTYLE_BIT_4; - pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; - pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_PENDING_RESTYLE_FLAGS; - pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; - pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_ALL_RESTYLE_FLAGS; - pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_HAS_SCROLLGRAB; - pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_84 = - _bindgen_ty_84::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; + root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_SHARED_RESTYLE_BIT_4; + pub const ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_IS_CONDITIONAL_RESTYLE_ANCESTOR; + pub const ELEMENT_PENDING_RESTYLE_FLAGS: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_PENDING_RESTYLE_FLAGS; + pub const ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_POTENTIAL_RESTYLE_ROOT_FLAGS; + pub const ELEMENT_ALL_RESTYLE_FLAGS: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_ALL_RESTYLE_FLAGS; + pub const ELEMENT_HAS_SCROLLGRAB: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_HAS_SCROLLGRAB; + pub const ELEMENT_TYPE_SPECIFIC_BITS_OFFSET: root::_bindgen_ty_74 = + _bindgen_ty_74::ELEMENT_TYPE_SPECIFIC_BITS_OFFSET; #[repr(u32)] #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] - pub enum _bindgen_ty_84 { + pub enum _bindgen_ty_74 { ELEMENT_SHARED_RESTYLE_BIT_1 = 8388608, ELEMENT_SHARED_RESTYLE_BIT_2 = 16777216, ELEMENT_SHARED_RESTYLE_BIT_3 = 33554432, @@ -31320,7 +31380,7 @@ pub mod root { } pub type __builtin_va_list = [root::__va_list_tag; 1usize]; #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_198488() { + fn __bindgen_test_layout_IntegralConstant_instantiation_175838() { assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -31329,7 +31389,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_IntegralConstant_instantiation_198492() { + fn __bindgen_test_layout_IntegralConstant_instantiation_175842() { assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( u8 ) )); @@ -31338,69 +31398,59 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_199316() { - assert_eq!(::std::mem::size_of::<root::nsReadingIterator<u16>>() , - 24usize , concat ! ( + fn __bindgen_test_layout_nsReadingIterator_instantiation_176671() { + assert_eq!(::std::mem::size_of::<root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<u16> ) )); - assert_eq!(::std::mem::align_of::<root::nsReadingIterator<u16>>() , - 8usize , concat ! ( + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<u16> ) )); + root::nsReadingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_199320() { - assert_eq!(::std::mem::size_of::<root::nsWritingIterator<u16>>() , - 24usize , concat ! ( + fn __bindgen_test_layout_nsWritingIterator_instantiation_176674() { + assert_eq!(::std::mem::size_of::<root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<u16> ) )); - assert_eq!(::std::mem::align_of::<root::nsWritingIterator<u16>>() , - 8usize , concat ! ( + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type>>() + , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<u16> ) )); + root::nsWritingIterator<root::mozilla::detail::nsStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsReadingIterator_instantiation_199393() { - assert_eq!(::std::mem::size_of::<root::nsReadingIterator<::std::os::raw::c_char>>() + fn __bindgen_test_layout_nsReadingIterator_instantiation_176746() { + assert_eq!(::std::mem::size_of::<root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::<root::nsReadingIterator<::std::os::raw::c_char>>() + root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsReadingIterator<::std::os::raw::c_char> ) )); + root::nsReadingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); } #[test] - fn __bindgen_test_layout_nsWritingIterator_instantiation_199397() { - assert_eq!(::std::mem::size_of::<root::nsWritingIterator<::std::os::raw::c_char>>() + fn __bindgen_test_layout_nsWritingIterator_instantiation_176749() { + assert_eq!(::std::mem::size_of::<root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - assert_eq!(::std::mem::align_of::<root::nsWritingIterator<::std::os::raw::c_char>>() + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type> + ) )); + assert_eq!(::std::mem::align_of::<root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type>>() , 8usize , concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsWritingIterator<::std::os::raw::c_char> ) )); - } - #[test] - fn __bindgen_test_layout__bindgen_ty_id_205166_instantiation_205163() { - assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( u8 ) - )); - assert_eq!(::std::mem::align_of::<u8>() , 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( u8 - ) )); - } - #[test] - fn __bindgen_test_layout__bindgen_ty_id_205199_instantiation_205196() { - assert_eq!(::std::mem::size_of::<u8>() , 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( u8 ) - )); - assert_eq!(::std::mem::align_of::<u8>() , 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( u8 + root::nsWritingIterator<root::mozilla::detail::nsCStringRepr_char_type> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_205467() { + fn __bindgen_test_layout_nsTArray_instantiation_181103() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCString>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31411,7 +31461,7 @@ pub mod root { root::nsTArray<root::nsCString> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_206419() { + fn __bindgen_test_layout_Handle_instantiation_181947() { assert_eq!(::std::mem::size_of::<root::JS::Handle<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31422,7 +31472,7 @@ pub mod root { root::JS::Handle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_Handle_instantiation_206435() { + fn __bindgen_test_layout_Handle_instantiation_181963() { assert_eq!(::std::mem::size_of::<root::JS::Handle<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31433,7 +31483,7 @@ pub mod root { root::JS::Handle<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_206445() { + fn __bindgen_test_layout_MutableHandle_instantiation_181973() { assert_eq!(::std::mem::size_of::<root::JS::MutableHandle<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31444,7 +31494,7 @@ pub mod root { root::JS::MutableHandle<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_MutableHandle_instantiation_206461() { + fn __bindgen_test_layout_MutableHandle_instantiation_181989() { assert_eq!(::std::mem::size_of::<root::JS::MutableHandle<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31455,7 +31505,7 @@ pub mod root { root::JS::MutableHandle<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_Rooted_instantiation_206464() { + fn __bindgen_test_layout_Rooted_instantiation_181992() { assert_eq!(::std::mem::size_of::<[u64; 3usize]>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31466,18 +31516,7 @@ pub mod root { [u64; 3usize] ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_206801() { - assert_eq!(::std::mem::size_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_208804() { + fn __bindgen_test_layout_nsTArray_instantiation_184495() { assert_eq!(::std::mem::size_of::<root::nsTArray<::nsstring::nsStringRepr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31488,7 +31527,7 @@ pub mod root { root::nsTArray<::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_208808() { + fn __bindgen_test_layout_nsTArray_instantiation_184499() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::FontFamilyName>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31499,18 +31538,18 @@ pub mod root { root::nsTArray<root::mozilla::FontFamilyName> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_208821() { - assert_eq!(::std::mem::size_of::<root::nsTArray<::std::os::raw::c_uint>>() - , 8usize , concat ! ( + fn __bindgen_test_layout_nsTArray_instantiation_184512() { + assert_eq!(::std::mem::size_of::<root::nsTArray<u32>>() , 8usize , + concat ! ( "Size of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); - assert_eq!(::std::mem::align_of::<root::nsTArray<::std::os::raw::c_uint>>() - , 8usize , concat ! ( + root::nsTArray<u32> ) )); + assert_eq!(::std::mem::align_of::<root::nsTArray<u32>>() , 8usize , + concat ! ( "Alignment of template specialization: " , stringify ! ( - root::nsTArray<::std::os::raw::c_uint> ) )); + root::nsTArray<u32> ) )); } #[test] - fn __bindgen_test_layout_TenuredHeap_instantiation_209688() { + fn __bindgen_test_layout_TenuredHeap_instantiation_185365() { assert_eq!(::std::mem::size_of::<root::JS::TenuredHeap>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31521,7 +31560,7 @@ pub mod root { root::JS::TenuredHeap ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_209778() { + fn __bindgen_test_layout_Heap_instantiation_185455() { assert_eq!(::std::mem::size_of::<root::JS::Heap<*mut root::JSObject>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31532,7 +31571,7 @@ pub mod root { root::JS::Heap<*mut root::JSObject> ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_209888() { + fn __bindgen_test_layout_TErrorResult_instantiation_185565() { assert_eq!(::std::mem::size_of::<root::mozilla::binding_danger::TErrorResult>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31543,7 +31582,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_TErrorResult_instantiation_209904() { + fn __bindgen_test_layout_TErrorResult_instantiation_185581() { assert_eq!(::std::mem::size_of::<root::mozilla::binding_danger::TErrorResult>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31554,7 +31593,7 @@ pub mod root { root::mozilla::binding_danger::TErrorResult ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_209909() { + fn __bindgen_test_layout_already_AddRefed_instantiation_185586() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsStringBuffer>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31565,7 +31604,7 @@ pub mod root { root::already_AddRefed<root::nsStringBuffer> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_209961() { + fn __bindgen_test_layout_already_AddRefed_instantiation_185638() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIAtom>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31576,7 +31615,7 @@ pub mod root { root::already_AddRefed<root::nsIAtom> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_210435() { + fn __bindgen_test_layout_RefPtr_instantiation_186112() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::StyleSheet>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31587,7 +31626,7 @@ pub mod root { root::RefPtr<root::mozilla::StyleSheet> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_210781() { + fn __bindgen_test_layout_already_AddRefed_instantiation_186458() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::dom::NodeInfo>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31598,7 +31637,7 @@ pub mod root { root::already_AddRefed<root::mozilla::dom::NodeInfo> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_211024() { + fn __bindgen_test_layout_already_AddRefed_instantiation_186701() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIURI>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31609,7 +31648,7 @@ pub mod root { root::already_AddRefed<root::nsIURI> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_211171() { + fn __bindgen_test_layout_already_AddRefed_instantiation_186848() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsINode>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31620,18 +31659,7 @@ pub mod root { root::already_AddRefed<root::nsINode> ) )); } #[test] - fn __bindgen_test_layout_DeletePolicy_instantiation_215266() { - assert_eq!(::std::mem::size_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Size of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - assert_eq!(::std::mem::align_of::<root::JS::DeletePolicy>() , 1usize , - concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::JS::DeletePolicy ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_215264() { + fn __bindgen_test_layout_UniquePtr_instantiation_190928() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::JSErrorNotes_Note>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31642,7 +31670,7 @@ pub mod root { root::mozilla::UniquePtr<root::JSErrorNotes_Note> ) )); } #[test] - fn __bindgen_test_layout_iterator_instantiation_215299() { + fn __bindgen_test_layout_iterator_instantiation_190960() { assert_eq!(::std::mem::size_of::<root::std::iterator>() , 1usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31653,7 +31681,7 @@ pub mod root { root::std::iterator ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_215865() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_191527() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31664,7 +31692,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_Heap_instantiation_217123() { + fn __bindgen_test_layout_Heap_instantiation_192775() { assert_eq!(::std::mem::size_of::<root::JS::Heap<root::JS::Value>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31675,7 +31703,7 @@ pub mod root { root::JS::Heap<root::JS::Value> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_217465() { + fn __bindgen_test_layout_nsTArray_instantiation_193117() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::AnonymousContent>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31688,7 +31716,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_LinkedList_instantiation_217741() { + fn __bindgen_test_layout_LinkedList_instantiation_193390() { assert_eq!(::std::mem::size_of::<root::mozilla::LinkedList>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31699,7 +31727,7 @@ pub mod root { root::mozilla::LinkedList ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_217757() { + fn __bindgen_test_layout_RefPtr_instantiation_193406() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::Element>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31710,7 +31738,7 @@ pub mod root { root::RefPtr<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_217756() { + fn __bindgen_test_layout_nsTArray_instantiation_193405() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::Element>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31723,7 +31751,7 @@ pub mod root { )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_217786() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_193435() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31734,7 +31762,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_217785() { + fn __bindgen_test_layout_nsTArray_instantiation_193434() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCOMPtr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31745,7 +31773,7 @@ pub mod root { root::nsTArray<root::nsCOMPtr> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_217831() { + fn __bindgen_test_layout_already_AddRefed_instantiation_193480() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIDocument>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31756,7 +31784,7 @@ pub mod root { root::already_AddRefed<root::nsIDocument> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_217996() { + fn __bindgen_test_layout_already_AddRefed_instantiation_193645() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsContentList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31767,7 +31795,7 @@ pub mod root { root::already_AddRefed<root::nsContentList> ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_218323() { + fn __bindgen_test_layout_already_AddRefed_instantiation_193972() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIRunnable>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31778,18 +31806,7 @@ pub mod root { root::already_AddRefed<root::nsIRunnable> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_218416() { - assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! - ( - "Size of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - assert_eq!(::std::mem::align_of::<root::nsCOMPtr>() , 8usize , concat - ! ( - "Alignment of template specialization: " , stringify ! ( - root::nsCOMPtr ) )); - } - #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_218453() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_194065() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31800,18 +31817,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_218709() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_218707() { + fn __bindgen_test_layout_UniquePtr_instantiation_194354() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsISMILAttr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31822,7 +31828,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsISMILAttr> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_219247() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_194891() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::mozilla::dom::DOMIntersectionObserver>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31835,7 +31841,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_219246() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_194890() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31846,7 +31852,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_219363() { + fn __bindgen_test_layout_nsTArray_instantiation_195006() { assert_eq!(::std::mem::size_of::<root::nsTArray<*mut root::nsIContent>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31857,7 +31863,7 @@ pub mod root { root::nsTArray<*mut root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_219410() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_195053() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -31866,7 +31872,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_219587() { + fn __bindgen_test_layout_nsTArray_instantiation_195230() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31877,18 +31883,7 @@ pub mod root { root::nsTArray<root::nsRect> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_219703() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_nsTArray_instantiation_219865() { + fn __bindgen_test_layout_nsTArray_instantiation_195505() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::nsCOMPtr>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31899,7 +31894,7 @@ pub mod root { root::nsTArray<root::nsCOMPtr> ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_220652() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_196292() { assert_eq!(::std::mem::size_of::<[u64; 28usize]>() , 224usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31910,7 +31905,7 @@ pub mod root { [u64; 28usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_220744() { + fn __bindgen_test_layout_already_AddRefed_instantiation_196384() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsIContent>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31921,7 +31916,7 @@ pub mod root { root::already_AddRefed<root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_220925() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_196565() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31932,7 +31927,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_221442() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_197082() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::WeakFrame>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31943,7 +31938,7 @@ pub mod root { root::nsPtrHashKey<root::WeakFrame> ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_221557() { + fn __bindgen_test_layout_OwningNonNull_instantiation_197197() { assert_eq!(::std::mem::size_of::<root::mozilla::OwningNonNull<root::nsINode>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31954,7 +31949,18 @@ pub mod root { root::mozilla::OwningNonNull<root::nsINode> ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_221842() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_197324() { + assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! + ( + "Size of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + assert_eq!(::std::mem::align_of::<root::nsCOMPtr>() , 8usize , concat + ! ( + "Alignment of template specialization: " , stringify ! ( + root::nsCOMPtr ) )); + } + #[test] + fn __bindgen_test_layout_nsPtrHashKey_instantiation_197484() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<::std::os::raw::c_void>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31965,7 +31971,7 @@ pub mod root { root::nsPtrHashKey<::std::os::raw::c_void> ) )); } #[test] - fn __bindgen_test_layout_PointTyped_instantiation_222633() { + fn __bindgen_test_layout_PointTyped_instantiation_198273() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31976,7 +31982,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_222638() { + fn __bindgen_test_layout_IntPointTyped_instantiation_198276() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31987,7 +31993,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SizeTyped_instantiation_222641() { + fn __bindgen_test_layout_SizeTyped_instantiation_198279() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -31998,7 +32004,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_222649() { + fn __bindgen_test_layout_RectTyped_instantiation_198285() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32009,7 +32015,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntPointTyped_instantiation_222681() { + fn __bindgen_test_layout_IntPointTyped_instantiation_198309() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32020,7 +32026,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntSizeTyped_instantiation_222689() { + fn __bindgen_test_layout_IntSizeTyped_instantiation_198315() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32031,7 +32037,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_222697() { + fn __bindgen_test_layout_IntRectTyped_instantiation_198321() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32042,7 +32048,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_MarginTyped_instantiation_222864() { + fn __bindgen_test_layout_MarginTyped_instantiation_198450() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32053,7 +32059,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_RectTyped_instantiation_222899() { + fn __bindgen_test_layout_RectTyped_instantiation_198477() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32064,7 +32070,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_IntRectTyped_instantiation_222904() { + fn __bindgen_test_layout_IntRectTyped_instantiation_198480() { assert_eq!(::std::mem::size_of::<[u32; 4usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32075,7 +32081,7 @@ pub mod root { [u32; 4usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactor_instantiation_222950() { + fn __bindgen_test_layout_ScaleFactor_instantiation_198516() { assert_eq!(::std::mem::size_of::<u32>() , 4usize , concat ! ( "Size of template specialization: " , stringify ! ( u32 ) )); @@ -32084,7 +32090,7 @@ pub mod root { u32 ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_223050() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_198616() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32095,7 +32101,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_223058() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_198624() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32106,7 +32112,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_ScaleFactors2D_instantiation_223102() { + fn __bindgen_test_layout_ScaleFactors2D_instantiation_198668() { assert_eq!(::std::mem::size_of::<[u32; 2usize]>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32117,7 +32123,7 @@ pub mod root { [u32; 2usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_223732() { + fn __bindgen_test_layout_nsTArray_instantiation_199298() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::FramePropertyTable_PropertyValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32130,7 +32136,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_223748() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_199314() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::nsIFrame>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32141,7 +32147,7 @@ pub mod root { root::nsPtrHashKey<root::nsIFrame> ) )); } #[test] - fn __bindgen_test_layout_nsPIDOMWindow_instantiation_227020() { + fn __bindgen_test_layout_nsPIDOMWindow_instantiation_202572() { assert_eq!(::std::mem::size_of::<[u64; 28usize]>() , 224usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32152,7 +32158,7 @@ pub mod root { [u64; 28usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_227650() { + fn __bindgen_test_layout_already_AddRefed_instantiation_203199() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::dom::CSSValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32163,18 +32169,7 @@ pub mod root { root::already_AddRefed<root::mozilla::dom::CSSValue> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_227741() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_227745() { + fn __bindgen_test_layout_nsRefPtrHashtable_instantiation_203291() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32185,7 +32180,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_228934() { + fn __bindgen_test_layout_already_AddRefed_instantiation_204480() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsISupports>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32196,7 +32191,7 @@ pub mod root { root::already_AddRefed<root::nsISupports> ) )); } #[test] - fn __bindgen_test_layout_nsCOMPtr_instantiation_229220() { + fn __bindgen_test_layout_nsCOMPtr_instantiation_204826() { assert_eq!(::std::mem::size_of::<root::nsCOMPtr>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32207,7 +32202,7 @@ pub mod root { root::nsCOMPtr ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_230810() { + fn __bindgen_test_layout_nsTArray_instantiation_206406() { assert_eq!(::std::mem::size_of::<root::nsTArray<f64>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32218,7 +32213,7 @@ pub mod root { root::nsTArray<f64> ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_230822() { + fn __bindgen_test_layout_RefPtr_instantiation_206418() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::DOMIntersectionObserverEntry>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32231,7 +32226,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_230821() { + fn __bindgen_test_layout_nsTArray_instantiation_206417() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::RefPtr<root::mozilla::dom::DOMIntersectionObserverEntry>>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32244,7 +32239,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_230855() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_206451() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::mozilla::dom::Element>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32255,7 +32250,7 @@ pub mod root { root::nsPtrHashKey<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_230952() { + fn __bindgen_test_layout_UniquePtr_instantiation_206548() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::ProfilerBacktrace>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32266,7 +32261,7 @@ pub mod root { root::mozilla::UniquePtr<root::ProfilerBacktrace> ) )); } #[test] - fn __bindgen_test_layout_nsDataHashtable_instantiation_232714() { + fn __bindgen_test_layout_nsDataHashtable_instantiation_208299() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32277,7 +32272,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_OwningNonNull_instantiation_232753() { + fn __bindgen_test_layout_OwningNonNull_instantiation_208338() { assert_eq!(::std::mem::size_of::<root::mozilla::OwningNonNull<root::mozilla::EffectCompositor_AnimationStyleRuleProcessor>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32290,7 +32285,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_232774() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_208359() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::nsIAtom>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32301,7 +32296,7 @@ pub mod root { root::nsRefPtrHashKey<root::nsIAtom> ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_232805() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_208390() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::nsIContent>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32312,18 +32307,7 @@ pub mod root { root::nsRefPtrHashKey<root::nsIContent> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_233350() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_233364() { + fn __bindgen_test_layout_already_AddRefed_instantiation_208946() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::mozilla::URLExtraData>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32334,7 +32318,7 @@ pub mod root { root::already_AddRefed<root::mozilla::URLExtraData> ) )); } #[test] - fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_233368() { + fn __bindgen_test_layout_nsMainThreadPtrHolder_instantiation_208950() { assert_eq!(::std::mem::size_of::<root::nsMainThreadPtrHolder<root::nsIURI>>() , 24usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32345,7 +32329,7 @@ pub mod root { root::nsMainThreadPtrHolder<root::nsIURI> ) )); } #[test] - fn __bindgen_test_layout_nsPtrHashKey_instantiation_233442() { + fn __bindgen_test_layout_nsPtrHashKey_instantiation_209024() { assert_eq!(::std::mem::size_of::<root::nsPtrHashKey<root::nsIDocument>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32356,18 +32340,7 @@ pub mod root { root::nsPtrHashKey<root::nsIDocument> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_233729() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_233727() { + fn __bindgen_test_layout_UniquePtr_instantiation_209309() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsCSSValueList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32378,18 +32351,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsCSSValueList> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_233735() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_233733() { + fn __bindgen_test_layout_UniquePtr_instantiation_209312() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsCSSValuePairList>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32400,7 +32362,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsCSSValuePairList> ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_234005() { + fn __bindgen_test_layout_Maybe_instantiation_209581() { assert_eq!(::std::mem::size_of::<[u64; 2usize]>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32411,7 +32373,7 @@ pub mod root { [u64; 2usize] ) )); } #[test] - fn __bindgen_test_layout_SupportsWeakPtr_instantiation_234172() { + fn __bindgen_test_layout_SupportsWeakPtr_instantiation_209747() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -32420,7 +32382,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_234320() { + fn __bindgen_test_layout_Maybe_instantiation_209897() { assert_eq!(::std::mem::size_of::<[u32; 3usize]>() , 12usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32431,7 +32393,7 @@ pub mod root { [u32; 3usize] ) )); } #[test] - fn __bindgen_test_layout_already_AddRefed_instantiation_234335() { + fn __bindgen_test_layout_already_AddRefed_instantiation_209912() { assert_eq!(::std::mem::size_of::<root::already_AddRefed<root::nsStyleImageRequest>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32442,18 +32404,7 @@ pub mod root { root::already_AddRefed<root::nsStyleImageRequest> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_234343() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_UniquePtr_instantiation_234341() { + fn __bindgen_test_layout_UniquePtr_instantiation_209918() { assert_eq!(::std::mem::size_of::<root::mozilla::UniquePtr<root::nsStyleSides>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32464,18 +32415,7 @@ pub mod root { root::mozilla::UniquePtr<root::nsStyleSides> ) )); } #[test] - fn __bindgen_test_layout_DefaultDelete_instantiation_234382() { - assert_eq!(::std::mem::size_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Size of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - assert_eq!(::std::mem::align_of::<root::mozilla::DefaultDelete>() , - 1usize , concat ! ( - "Alignment of template specialization: " , stringify ! ( - root::mozilla::DefaultDelete ) )); - } - #[test] - fn __bindgen_test_layout_pair_instantiation_234533() { + fn __bindgen_test_layout_pair_instantiation_210104() { assert_eq!(::std::mem::size_of::<root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr>>() , 32usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32486,7 +32426,7 @@ pub mod root { root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr> ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_234532() { + fn __bindgen_test_layout_nsTArray_instantiation_210103() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::std::pair<::nsstring::nsStringRepr, ::nsstring::nsStringRepr>>>() , 8usize , concat ! ( @@ -32501,7 +32441,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_235534() { + fn __bindgen_test_layout_RefPtr_instantiation_211105() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::RawServoAnimationValue>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32512,7 +32452,7 @@ pub mod root { root::RefPtr<root::RawServoAnimationValue> ) )); } #[test] - fn __bindgen_test_layout_BaseTimeDuration_instantiation_239526() { + fn __bindgen_test_layout_BaseTimeDuration_instantiation_215093() { assert_eq!(::std::mem::size_of::<root::mozilla::BaseTimeDuration>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32523,7 +32463,7 @@ pub mod root { root::mozilla::BaseTimeDuration ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_240118() { + fn __bindgen_test_layout_nsTArray_instantiation_215685() { assert_eq!(::std::mem::size_of::<root::nsTArray<root::mozilla::DisplayItemClip_RoundedRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32536,7 +32476,7 @@ pub mod root { ) )); } #[test] - fn __bindgen_test_layout_Maybe_instantiation_240294() { + fn __bindgen_test_layout_Maybe_instantiation_215859() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32547,7 +32487,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_RefPtr_instantiation_240469() { + fn __bindgen_test_layout_RefPtr_instantiation_216034() { assert_eq!(::std::mem::size_of::<root::RefPtr<root::mozilla::dom::DOMRect>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32558,7 +32498,7 @@ pub mod root { root::RefPtr<root::mozilla::dom::DOMRect> ) )); } #[test] - fn __bindgen_test_layout_Sequence_instantiation_240713() { + fn __bindgen_test_layout_Sequence_instantiation_216278() { assert_eq!(::std::mem::size_of::<u64>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( u64 ) )); @@ -32567,7 +32507,7 @@ pub mod root { u64 ) )); } #[test] - fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_241012() { + fn __bindgen_test_layout_nsRefPtrHashKey_instantiation_216577() { assert_eq!(::std::mem::size_of::<root::nsRefPtrHashKey<root::mozilla::dom::Element>>() , 16usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32578,7 +32518,7 @@ pub mod root { root::nsRefPtrHashKey<root::mozilla::dom::Element> ) )); } #[test] - fn __bindgen_test_layout_nsClassHashtable_instantiation_241011() { + fn __bindgen_test_layout_nsClassHashtable_instantiation_216576() { assert_eq!(::std::mem::size_of::<[u64; 5usize]>() , 40usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32589,7 +32529,7 @@ pub mod root { [u64; 5usize] ) )); } #[test] - fn __bindgen_test_layout_nsTArray_instantiation_242145() { + fn __bindgen_test_layout_nsTArray_instantiation_217717() { assert_eq!(::std::mem::size_of::<root::nsTArray<*mut root::mozilla::css::DocumentRule>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( @@ -32600,7 +32540,7 @@ pub mod root { root::nsTArray<*mut root::mozilla::css::DocumentRule> ) )); } #[test] - fn __bindgen_test_layout_nsAutoPtr_instantiation_242181() { + fn __bindgen_test_layout_nsAutoPtr_instantiation_217753() { assert_eq!(::std::mem::size_of::<root::nsAutoPtr<root::nsMediaQuery>>() , 8usize , concat ! ( "Size of template specialization: " , stringify ! ( diff --git a/components/style/gecko/mod.rs b/components/style/gecko/mod.rs index 92582823527..cfdf45d43b8 100644 --- a/components/style/gecko/mod.rs +++ b/components/style/gecko/mod.rs @@ -12,6 +12,7 @@ pub mod conversions; pub mod data; pub mod global_style_data; pub mod media_queries; +pub mod pseudo_element; pub mod restyle_damage; pub mod rules; pub mod selector_parser; diff --git a/components/style/gecko/pseudo_element.rs b/components/style/gecko/pseudo_element.rs new file mode 100644 index 00000000000..f5793499108 --- /dev/null +++ b/components/style/gecko/pseudo_element.rs @@ -0,0 +1,71 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * 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/. */ + +//! Gecko's definition of a pseudo-element. +//! +//! Note that a few autogenerated bits of this live in +//! `pseudo_element_definition.mako.rs`. If you touch that file, you probably +//! need to update the checked-in files for Servo. + +use cssparser::ToCss; +use gecko_bindings::structs::CSSPseudoElementType; +use selector_parser::PseudoElementCascadeType; +use std::fmt; +use string_cache::Atom; + +include!(concat!(env!("OUT_DIR"), "/gecko/pseudo_element_definition.rs")); + +impl PseudoElement { + /// Returns the kind of cascade type that a given pseudo is going to use. + /// + /// In Gecko we only compute ::before and ::after eagerly. We save the rules + /// for anonymous boxes separately, so we resolve them as precomputed + /// pseudos. + /// + /// We resolve the others lazily, see `Servo_ResolvePseudoStyle`. + pub fn cascade_type(&self) -> PseudoElementCascadeType { + if self.is_eager() { + debug_assert!(!self.is_anon_box()); + return PseudoElementCascadeType::Eager + } + + if self.is_anon_box() { + return PseudoElementCascadeType::Precomputed + } + + PseudoElementCascadeType::Lazy + } + + /// Gets the canonical index of this eagerly-cascaded pseudo-element. + #[inline] + pub fn eager_index(&self) -> usize { + EAGER_PSEUDOS.iter().position(|p| p == self) + .expect("Not an eager pseudo") + } + + /// Creates a pseudo-element from an eager index. + #[inline] + pub fn from_eager_index(i: usize) -> Self { + EAGER_PSEUDOS[i].clone() + } + + /// Whether this pseudo-element is ::before or ::after. + #[inline] + pub fn is_before_or_after(&self) -> bool { + matches!(*self, PseudoElement::Before | PseudoElement::After) + } + + /// Whether this pseudo-element is lazily-cascaded. + #[inline] + pub fn is_lazy(&self) -> bool { + !self.is_eager() && !self.is_precomputed() + } +} + +impl ToCss for PseudoElement { + fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { + dest.write_char(':')?; + dest.write_str(self.as_str()) + } +} diff --git a/components/style/gecko/pseudo_element_definition.mako.rs b/components/style/gecko/pseudo_element_definition.mako.rs new file mode 100644 index 00000000000..0872ed9a9a2 --- /dev/null +++ b/components/style/gecko/pseudo_element_definition.mako.rs @@ -0,0 +1,128 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * 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/. */ + +/// Gecko's pseudo-element definition. +#[derive(Clone, Debug, PartialEq, Eq, Hash)] +pub enum PseudoElement { + % for pseudo in PSEUDOS: + /// ${pseudo.value} + ${pseudo.capitalized()}, + % endfor +} + +<% EAGER_PSEUDOS = ["Before", "After"] %> + +/// The number of eager pseudo-elements. +pub const EAGER_PSEUDO_COUNT: usize = ${len(EAGER_PSEUDOS)}; + +/// The list of eager pseudos. +pub const EAGER_PSEUDOS: [PseudoElement; EAGER_PSEUDO_COUNT] = [ + % for eager_pseudo_name in EAGER_PSEUDOS: + PseudoElement::${eager_pseudo_name}, + % endfor +]; + +impl PseudoElement { + /// Executes a closure with each pseudo-element as an argument. + pub fn each<F>(mut fun: F) + where F: FnMut(Self), + { + % for pseudo in PSEUDOS: + fun(PseudoElement::${pseudo.capitalized()}); + % endfor + } + + /// Get the pseudo-element as an atom. + #[inline] + pub fn atom(&self) -> Atom { + match *self { + % for pseudo in PSEUDOS: + PseudoElement::${pseudo.capitalized()} => atom!("${pseudo.value}"), + % endfor + } + } + + /// Whether this pseudo-element is an anonymous box. + #[inline] + fn is_anon_box(&self) -> bool { + match *self { + % for pseudo in PSEUDOS: + PseudoElement::${pseudo.capitalized()} => ${str(pseudo.is_anon_box()).lower()}, + % endfor + } + } + + /// Whether this pseudo-element is eagerly-cascaded. + #[inline] + pub fn is_eager(&self) -> bool { + matches!(*self, + ${" | ".join(map(lambda name: "PseudoElement::{}".format(name), EAGER_PSEUDOS))}) + } + + /// Whether this pseudo-element is precomputed. + #[inline] + pub fn is_precomputed(&self) -> bool { + self.is_anon_box() + } + + /// Construct a pseudo-element from a `CSSPseudoElementType`. + #[inline] + pub fn from_pseudo_type(type_: CSSPseudoElementType) -> Option<Self> { + match type_ { + % for pseudo in PSEUDOS: + % if not pseudo.is_anon_box(): + CSSPseudoElementType::${pseudo.original_ident} => { + Some(PseudoElement::${pseudo.capitalized()}) + }, + % endif + % endfor + _ => None, + } + } + + /// Construct a pseudo-element from an anonymous box `Atom`. + #[inline] + pub fn from_anon_box_atom(atom: &Atom) -> Option<Self> { + % for pseudo in PSEUDOS: + % if pseudo.is_anon_box(): + if atom == &atom!("${pseudo.value}") { + return Some(PseudoElement::${pseudo.capitalized()}); + } + % endif + % endfor + None + } + + /// Constructs an atom from a string of text, and whether we're in a + /// user-agent stylesheet. + /// + /// If we're not in a user-agent stylesheet, we will never parse anonymous + /// box pseudo-elements. + /// + /// Returns `None` if the pseudo-element is not recognised. + #[inline] + pub fn from_slice(s: &str, in_ua_stylesheet: bool) -> Option<Self> { + use std::ascii::AsciiExt; + + % for pseudo in PSEUDOS: + if !${str(pseudo.is_anon_box()).lower()} || in_ua_stylesheet { + if s.eq_ignore_ascii_case("${pseudo.value[1:]}") { + return Some(PseudoElement::${pseudo.capitalized()}) + } + } + % endfor + + None + } + + /// Returns the pseudo-element's definition as a string, with only one colon + /// before it. + pub fn as_str(&self) -> &'static str { + match *self { + % for pseudo in PSEUDOS: + PseudoElement::${pseudo.capitalized()} => "${pseudo.value}", + % endfor + } + } +} diff --git a/components/style/binding_tools/regen_atoms.py b/components/style/gecko/regen_atoms.py index 05acee47a7d..810729c2d2a 100755 --- a/components/style/binding_tools/regen_atoms.py +++ b/components/style/gecko/regen_atoms.py @@ -10,6 +10,10 @@ import sys from io import BytesIO +GECKO_DIR = os.path.dirname(__file__.replace('\\', '/')) +sys.path.insert(0, os.path.join(os.path.dirname(GECKO_DIR), "properties")) + +import build PRELUDE = """ /* This Source Code Form is subject to the terms of the Mozilla Public @@ -74,7 +78,7 @@ def map_atom(ident): class Atom: def __init__(self, source, ident, value): self.ident = "{}_{}".format(source.CLASS, ident) - self._original_ident = ident + self.original_ident = ident self.value = value self.source = source @@ -82,17 +86,23 @@ class Atom: return self.source.CLASS def gnu_symbol(self): - return gnu_symbolify(self.source, self._original_ident) + return gnu_symbolify(self.source, self.original_ident) def msvc32_symbol(self): - return msvc32_symbolify(self.source, self._original_ident) + return msvc32_symbolify(self.source, self.original_ident) def msvc64_symbol(self): - return msvc64_symbolify(self.source, self._original_ident) + return msvc64_symbolify(self.source, self.original_ident) def type(self): return self.source.TYPE + def capitalized(self): + return self.original_ident[0].upper() + self.original_ident[1:] + + def is_anon_box(self): + return self.type() == "nsICSSAnonBoxPseudo" + def collect_atoms(objdir): atoms = [] @@ -211,56 +221,24 @@ def write_atom_macro(atoms, file_name): f.write(MACRO.format('\n'.join(macro_rules))) -PSEUDO_ELEMENT_HEADER = """ -/* - * This file contains a helper macro invocation to aid Gecko's style system - * pseudo-element integration. - * - * This file is NOT INTENDED to be compiled as a standalone module. - * - * Also, it guarantees the property that normal pseudo-elements are processed - * before anonymous boxes. - * - * Expected usage is as follows: - * - * ``` - * fn have_to_use_pseudo_elements() { - * macro_rules! pseudo_element { - * ($pseudo_str_with_colon:expr, $pseudo_atom:expr, $is_anon_box:true) => {{ - * // Stuff stuff stuff. - * }} - * } - * include!("path/to/helper.rs") - * } - * ``` - * - */ -""" - -PSEUDO_ELEMENT_MACRO_INVOCATION = """ - pseudo_element!(\"{}\", - atom!(\"{}\"), - {}); -"""[1:] +def write_pseudo_elements(atoms, target_filename): + pseudos = [] + for atom in atoms: + if atom.type() == "nsICSSPseudoElement" or atom.type() == "nsICSSAnonBoxPseudo": + pseudos.append(atom) + pseudo_definition_template = os.path.join(GECKO_DIR, "pseudo_element_definition.mako.rs") + print("cargo:rerun-if-changed={}".format(pseudo_definition_template)) + contents = build.render(pseudo_definition_template, PSEUDOS=pseudos) -def write_pseudo_element_helper(atoms, target_filename): with FileAvoidWrite(target_filename) as f: - f.write(PRELUDE) - f.write(PSEUDO_ELEMENT_HEADER) - f.write("{\n") - for atom in atoms: - if atom.type() == "nsICSSPseudoElement": - f.write(PSEUDO_ELEMENT_MACRO_INVOCATION.format(atom.value, atom.value, "false")) - elif atom.type() == "nsICSSAnonBoxPseudo": - f.write(PSEUDO_ELEMENT_MACRO_INVOCATION.format(atom.value, atom.value, "true")) - f.write("}\n") + f.write(contents) def generate_atoms(dist, out): atoms = collect_atoms(dist) write_atom_macro(atoms, os.path.join(out, "atom_macro.rs")) - write_pseudo_element_helper(atoms, os.path.join(out, "pseudo_element_helper.rs")) + write_pseudo_elements(atoms, os.path.join(out, "pseudo_element_definition.rs")) if __name__ == "__main__": diff --git a/components/style/gecko/selector_parser.rs b/components/style/gecko/selector_parser.rs index 459305672e1..9c67c06d60a 100644 --- a/components/style/gecko/selector_parser.rs +++ b/components/style/gecko/selector_parser.rs @@ -8,213 +8,16 @@ use cssparser::{Parser, ToCss}; use element_state::{IN_ACTIVE_STATE, IN_FOCUS_STATE, IN_HOVER_STATE}; use element_state::ElementState; use gecko_bindings::structs::CSSPseudoClassType; -use gecko_bindings::structs::nsIAtom; use selector_parser::{SelectorParser, PseudoElementCascadeType}; use selectors::parser::{ComplexSelector, SelectorMethods}; use selectors::visitor::SelectorVisitor; use std::borrow::Cow; use std::fmt; -use std::ptr; use string_cache::{Atom, Namespace, WeakAtom, WeakNamespace}; +pub use gecko::pseudo_element::{PseudoElement, EAGER_PSEUDOS, EAGER_PSEUDO_COUNT}; pub use gecko::snapshot::SnapshotMap; -/// A representation of a CSS pseudo-element. -/// -/// In Gecko, we represent pseudo-elements as plain `Atom`s. -/// -/// The boolean field represents whether this element is an anonymous box. This -/// is just for convenience, instead of recomputing it. -/// -/// Also, note that the `Atom` member is always a static atom, so if space is a -/// concern, we can use the raw pointer and use the lower bit to represent it -/// without space overhead. -/// -/// FIXME(emilio): we know all these atoms are static. Patches are starting to -/// pile up, but a further potential optimisation is generating bindings without -/// `-no-gen-bitfield-methods` (that was removed to compile on stable, but it no -/// longer depends on it), and using the raw *mut nsIAtom (properly asserting -/// we're a static atom). -/// -/// This should allow us to avoid random FFI overhead when cloning/dropping -/// pseudos. -/// -/// Also, we can further optimize PartialEq and hash comparing/hashing only the -/// atoms. -#[derive(Clone, Debug, PartialEq, Eq, Hash)] -pub struct PseudoElement(Atom, bool); - -/// List of eager pseudos. Keep this in sync with the count below. -macro_rules! each_eager_pseudo { - ($macro_name:ident, $atom_macro:ident) => { - $macro_name!($atom_macro!(":after"), 0); - $macro_name!($atom_macro!(":before"), 1); - } -} - -/// The number of eager pseudo-elements (just ::before and ::after). -pub const EAGER_PSEUDO_COUNT: usize = 2; - - -impl PseudoElement { - /// Returns the kind of cascade type that a given pseudo is going to use. - /// - /// In Gecko we only compute ::before and ::after eagerly. We save the rules - /// for anonymous boxes separately, so we resolve them as precomputed - /// pseudos. - /// - /// We resolve the others lazily, see `Servo_ResolvePseudoStyle`. - pub fn cascade_type(&self) -> PseudoElementCascadeType { - if self.is_eager() { - debug_assert!(!self.is_anon_box()); - return PseudoElementCascadeType::Eager - } - - if self.is_anon_box() { - return PseudoElementCascadeType::Precomputed - } - - PseudoElementCascadeType::Lazy - } - - /// Gets the canonical index of this eagerly-cascaded pseudo-element. - #[inline] - pub fn eager_index(&self) -> usize { - macro_rules! case { - ($atom:expr, $idx:expr) => { if *self.as_atom() == $atom { return $idx; } } - } - each_eager_pseudo!(case, atom); - panic!("Not eager") - } - - /// Creates a pseudo-element from an eager index. - #[inline] - pub fn from_eager_index(i: usize) -> Self { - macro_rules! case { - ($atom:expr, $idx:expr) => { if i == $idx { return PseudoElement($atom, false); } } - } - each_eager_pseudo!(case, atom); - panic!("Not eager") - } - - /// Get the pseudo-element as an atom. - #[inline] - pub fn as_atom(&self) -> &Atom { - &self.0 - } - - /// Whether this pseudo-element is an anonymous box. - #[inline] - fn is_anon_box(&self) -> bool { - self.1 - } - - /// Whether this pseudo-element is ::before or ::after. - #[inline] - pub fn is_before_or_after(&self) -> bool { - *self.as_atom() == atom!(":before") || - *self.as_atom() == atom!(":after") - } - - /// Whether this pseudo-element is eagerly-cascaded. - #[inline] - pub fn is_eager(&self) -> bool { - macro_rules! case { - ($atom:expr, $idx:expr) => { if *self.as_atom() == $atom { return true; } } - } - each_eager_pseudo!(case, atom); - return false; - } - - /// Whether this pseudo-element is lazily-cascaded. - #[inline] - pub fn is_lazy(&self) -> bool { - !self.is_eager() && !self.is_precomputed() - } - - /// Whether this pseudo-element is precomputed. - #[inline] - pub fn is_precomputed(&self) -> bool { - self.is_anon_box() - } - - /// Construct a pseudo-element from an `Atom`, receiving whether it is also - /// an anonymous box, and don't check it on release builds. - /// - /// On debug builds we assert it's the result we expect. - #[inline] - pub fn from_atom_unchecked(atom: Atom, is_anon_box: bool) -> Self { - if cfg!(debug_assertions) { - // Do the check on debug regardless. - match Self::from_atom(&*atom, true) { - Some(pseudo) => { - assert_eq!(pseudo.is_anon_box(), is_anon_box); - return pseudo; - } - None => panic!("Unknown pseudo: {:?}", atom), - } - } - - PseudoElement(atom, is_anon_box) - } - - #[inline] - fn from_atom(atom: &WeakAtom, _in_ua: bool) -> Option<Self> { - macro_rules! pseudo_element { - ($pseudo_str_with_colon:expr, $atom:expr, $is_anon_box:expr) => {{ - if atom == &*$atom { - return Some(PseudoElement($atom, $is_anon_box)); - } - }} - } - - include!(concat!(env!("OUT_DIR"), "/gecko/pseudo_element_helper.rs")); - - None - } - - /// Constructs an atom from a string of text, and whether we're in a - /// user-agent stylesheet. - /// - /// If we're not in a user-agent stylesheet, we will never parse anonymous - /// box pseudo-elements. - /// - /// Returns `None` if the pseudo-element is not recognised. - #[inline] - fn from_slice(s: &str, in_ua_stylesheet: bool) -> Option<Self> { - use std::ascii::AsciiExt; - macro_rules! pseudo_element { - ($pseudo_str_with_colon:expr, $atom:expr, $is_anon_box:expr) => {{ - if !$is_anon_box || in_ua_stylesheet { - if s.eq_ignore_ascii_case(&$pseudo_str_with_colon[1..]) { - return Some(PseudoElement($atom, $is_anon_box)) - } - } - }} - } - - include!(concat!(env!("OUT_DIR"), "/gecko/pseudo_element_helper.rs")); - - None - } - - /// Returns null or nsIAtom pointer corresponding to a given PseudoElement. - #[inline] - pub fn ns_atom_or_null_from_opt(pseudo: Option<&PseudoElement>) -> *mut nsIAtom { - pseudo.map(|p| p.as_atom().as_ptr()).unwrap_or(ptr::null_mut()) - } -} - -impl ToCss for PseudoElement { - fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { - // FIXME: why does the atom contain one colon? Pseudo-element has two - debug_assert!(self.0.as_slice().starts_with(&[b':' as u16]) && - !self.0.as_slice().starts_with(&[b':' as u16, b':' as u16])); - try!(dest.write_char(':')); - write!(dest, "{}", self.0) - } -} - bitflags! { flags NonTSPseudoClassFlag: u8 { // See NonTSPseudoClass::is_internal() @@ -561,25 +364,18 @@ impl SelectorImpl { pub fn each_eagerly_cascaded_pseudo_element<F>(mut fun: F) where F: FnMut(PseudoElement), { - macro_rules! case { - ($atom:expr, $idx:expr) => { fun(PseudoElement($atom, false)); } + for pseudo in &EAGER_PSEUDOS { + fun(pseudo.clone()) } - each_eager_pseudo!(case, atom); } #[inline] /// Executes a function for each pseudo-element. - pub fn each_pseudo_element<F>(mut fun: F) + pub fn each_pseudo_element<F>(fun: F) where F: FnMut(PseudoElement), { - macro_rules! pseudo_element { - ($pseudo_str_with_colon:expr, $atom:expr, $is_anon_box:expr) => {{ - fun(PseudoElement($atom, $is_anon_box)); - }} - } - - include!(concat!(env!("OUT_DIR"), "/gecko/pseudo_element_helper.rs")); + PseudoElement::each(fun) } #[inline] diff --git a/components/style/gecko/wrapper.rs b/components/style/gecko/wrapper.rs index 6558fbc38a1..41224c0b403 100644 --- a/components/style/gecko/wrapper.rs +++ b/components/style/gecko/wrapper.rs @@ -627,7 +627,8 @@ impl<'le> TElement for GeckoElement<'le> { _existing_values: &'a Arc<ComputedValues>, pseudo: Option<&PseudoElement>) -> Option<&'a nsStyleContext> { - let atom_ptr = PseudoElement::ns_atom_or_null_from_opt(pseudo); + // TODO(emilio): Migrate this to CSSPseudoElementType. + let atom_ptr = pseudo.map_or(ptr::null_mut(), |p| p.atom().as_ptr()); unsafe { let context_ptr = Gecko_GetStyleContext(self.0, atom_ptr); context_ptr.as_ref() @@ -699,15 +700,9 @@ impl<'le> TElement for GeckoElement<'le> { return None; } - let maybe_atom = + let pseudo_type = unsafe { bindings::Gecko_GetImplementedPseudo(self.0) }; - - if maybe_atom.is_null() { - return None; - } - - let atom = Atom::from(maybe_atom); - Some(PseudoElement::from_atom_unchecked(atom, /* anon_box = */ false)) + PseudoElement::from_pseudo_type(pseudo_type) } fn store_children_to_process(&self, _: isize) { diff --git a/ports/geckolib/glue.rs b/ports/geckolib/glue.rs index 439f4d82bb1..1a673afc790 100644 --- a/ports/geckolib/glue.rs +++ b/ports/geckolib/glue.rs @@ -58,10 +58,10 @@ 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::{RawServoStyleRule, ServoStyleSheet}; use style::gecko_bindings::structs::{SheetParsingMode, nsIAtom, nsCSSPropertyID}; use style::gecko_bindings::structs::{nsRestyleHint, nsChangeHint, nsCSSFontFaceRule}; -use style::gecko_bindings::structs::CompositeOperation; use style::gecko_bindings::structs::Loader; use style::gecko_bindings::structs::RawGeckoPresContextOwned; use style::gecko_bindings::structs::ServoElementSnapshotTable; @@ -474,7 +474,7 @@ pub extern "C" fn Servo_AnimationValue_Uncompute(value: RawServoAnimationValueBo pub extern "C" fn Servo_StyleSet_GetBaseComputedValuesForElement(raw_data: RawServoStyleSetBorrowed, element: RawGeckoElementBorrowed, snapshots: *const ServoElementSnapshotTable, - pseudo_tag: *mut nsIAtom) + pseudo_type: CSSPseudoElementType) -> ServoComputedValuesStrong { use style::matching::MatchMethods; @@ -492,12 +492,7 @@ pub extern "C" fn Servo_StyleSet_GetBaseComputedValuesForElement(raw_data: RawSe let element_data = element.borrow_data().unwrap(); let styles = element_data.styles(); - let pseudo = if pseudo_tag.is_null() { - None - } else { - let atom = Atom::from(pseudo_tag); - Some(PseudoElement::from_atom_unchecked(atom, /* anon_box = */ false)) - }; + let pseudo = PseudoElement::from_pseudo_type(pseudo_type); let pseudos = &styles.pseudos; let pseudo_style = match pseudo { Some(ref p) => { @@ -974,7 +969,8 @@ pub extern "C" fn Servo_ComputedValues_GetForAnonymousBox(parent_style_or_null: let guards = StylesheetGuards::same(&guard); let data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut(); let atom = Atom::from(pseudo_tag); - let pseudo = PseudoElement::from_atom_unchecked(atom, /* anon_box = */ true); + let pseudo = PseudoElement::from_anon_box_atom(&atom) + .expect("Not an anon box pseudo?"); let maybe_parent = ComputedValues::arc_from_borrowed(&parent_style_or_null); @@ -991,7 +987,7 @@ pub extern "C" fn Servo_ComputedValues_GetForAnonymousBox(parent_style_or_null: #[no_mangle] pub extern "C" fn Servo_ResolvePseudoStyle(element: RawGeckoElementBorrowed, - pseudo_tag: *mut nsIAtom, + pseudo_type: CSSPseudoElementType, is_probe: bool, raw_data: RawServoStyleSetBorrowed) -> ServoComputedValuesStrong @@ -1010,9 +1006,12 @@ pub extern "C" fn Servo_ResolvePseudoStyle(element: RawGeckoElementBorrowed, }; } + let pseudo = PseudoElement::from_pseudo_type(pseudo_type) + .expect("ResolvePseudoStyle with a non-pseudo?"); + let global_style_data = &*GLOBAL_STYLE_DATA; let guard = global_style_data.shared_lock.read(); - match get_pseudo_style(&guard, element, pseudo_tag, data.styles(), doc_data) { + match get_pseudo_style(&guard, element, &pseudo, data.styles(), doc_data) { Some(values) => values.into_strong(), // FIXME(emilio): This looks pretty wrong! Shouldn't it be at least an // empty style inheriting from the element? @@ -1043,12 +1042,11 @@ pub extern "C" fn Servo_HasAuthorSpecifiedRules(element: RawGeckoElementBorrowed fn get_pseudo_style(guard: &SharedRwLockReadGuard, element: GeckoElement, - pseudo_tag: *mut nsIAtom, + pseudo: &PseudoElement, styles: &ElementStyles, doc_data: &PerDocumentStyleData) -> Option<Arc<ComputedValues>> { - let pseudo = PseudoElement::from_atom_unchecked(Atom::from(pseudo_tag), false); match pseudo.cascade_type() { PseudoElementCascadeType::Eager => styles.pseudos.get(&pseudo).map(|s| s.values().clone()), PseudoElementCascadeType::Precomputed => unreachable!("No anonymous boxes"), @@ -1981,7 +1979,7 @@ pub extern "C" fn Servo_ResolveStyle(element: RawGeckoElementBorrowed, #[no_mangle] pub extern "C" fn Servo_ResolveStyleLazily(element: RawGeckoElementBorrowed, - pseudo_tag: *mut nsIAtom, + pseudo_type: CSSPseudoElementType, snapshots: *const ServoElementSnapshotTable, raw_data: RawServoStyleSetBorrowed) -> ServoComputedValuesStrong @@ -1992,12 +1990,9 @@ pub extern "C" fn Servo_ResolveStyleLazily(element: RawGeckoElementBorrowed, let element = GeckoElement(element); let doc_data = PerDocumentStyleData::from_ffi(raw_data); let finish = |styles: &ElementStyles| -> Arc<ComputedValues> { - let maybe_pseudo = if !pseudo_tag.is_null() { - get_pseudo_style(&guard, element, pseudo_tag, styles, doc_data) - } else { - None - }; - maybe_pseudo.unwrap_or_else(|| styles.primary.values().clone()) + PseudoElement::from_pseudo_type(pseudo_type).and_then(|ref pseudo| { + get_pseudo_style(&guard, element, pseudo, styles, doc_data) + }).unwrap_or_else(|| styles.primary.values().clone()) }; // In the common case we already have the style. Check that before setting diff --git a/tests/unit/stylo/sanity_checks.rs b/tests/unit/stylo/sanity_checks.rs index ce0576fe6cf..c7558d3055c 100644 --- a/tests/unit/stylo/sanity_checks.rs +++ b/tests/unit/stylo/sanity_checks.rs @@ -26,28 +26,3 @@ macro_rules! check_enum_value_non_static { assert_eq!($a.0 as usize, $b as usize); } } - -// Note that we can't call each_pseudo_element, parse_pseudo_element, or -// similar, because we'd need the foreign atom symbols to link. -#[test] -fn assert_basic_pseudo_elements() { - let saw_before; - let saw_after; - - macro_rules! pseudo_element { - (":before", $atom:expr, false) => { - saw_before = true; - }; - (":after", $atom:expr, false) => { - saw_after = true; - }; - ($pseudo_str_with_colon:expr, $atom:expr, $is_anon_box:expr) => { - // Do nothing - }; - } - - include!("../../../components/style/gecko/generated/pseudo_element_helper.rs"); - - assert!(saw_before); - assert!(saw_after); -} |