mirror of
https://github.com/servo/servo.git
synced 2025-07-02 21:13:39 +01:00
Update the style crate's bindgen dependency
This commit is contained in:
parent
a5fe464e4a
commit
1cfd3ce5d3
6 changed files with 70 additions and 55 deletions
|
@ -65,6 +65,6 @@ kernel32-sys = "0.2"
|
|||
[build-dependencies]
|
||||
lazy_static = "0.2"
|
||||
log = "0.3"
|
||||
bindgen = { version = "0.22", optional = true }
|
||||
bindgen = { version = "0.24", optional = true }
|
||||
regex = {version = "0.2", optional = true}
|
||||
walkdir = "1.0"
|
||||
|
|
|
@ -28,7 +28,7 @@ mod common {
|
|||
#[cfg(feature = "bindgen")]
|
||||
mod bindings {
|
||||
use bindgen::{Builder, CodegenConfig};
|
||||
use bindgen::chooser::{EnumVariantCustomBehavior, EnumVariantValue, TypeChooser};
|
||||
use bindgen::callbacks::{EnumVariantCustomBehavior, EnumVariantValue, ParseCallbacks};
|
||||
use regex::Regex;
|
||||
use std::cmp;
|
||||
use std::collections::HashSet;
|
||||
|
@ -270,7 +270,7 @@ mod bindings {
|
|||
|
||||
#[derive(Debug)]
|
||||
struct Callbacks;
|
||||
impl TypeChooser for Callbacks {
|
||||
impl ParseCallbacks for Callbacks {
|
||||
fn enum_variant_behavior(&self,
|
||||
enum_name: Option<&str>,
|
||||
variant_name: &str,
|
||||
|
@ -293,10 +293,10 @@ mod bindings {
|
|||
vars: true,
|
||||
..CodegenConfig::nothing()
|
||||
})
|
||||
.include(add_include("nsCSSPseudoClasses.h")) // servo/rust-bindgen#599
|
||||
.header(add_include("nsStyleStruct.h"))
|
||||
.header(add_include("nsCSSPseudoClasses.h")) // servo/rust-bindgen#599
|
||||
.include(add_include("nsStyleStruct.h"))
|
||||
.include(add_include("mozilla/ServoPropPrefList.h"))
|
||||
.header(add_include("mozilla/StyleAnimationValue.h"))
|
||||
.include(add_include("mozilla/StyleAnimationValue.h"))
|
||||
.include(add_include("gfxFontConstants.h"))
|
||||
.include(add_include("nsThemeConstants.h"))
|
||||
.include(add_include("mozilla/dom/AnimationEffectReadOnlyBinding.h"))
|
||||
|
@ -324,7 +324,7 @@ mod bindings {
|
|||
.bitfield_enum("nsChangeHint")
|
||||
.bitfield_enum("nsRestyleHint")
|
||||
.constified_enum("UpdateAnimationsTasks")
|
||||
.type_chooser(Box::new(Callbacks));
|
||||
.parse_callbacks(Box::new(Callbacks));
|
||||
let whitelist_vars = [
|
||||
"NS_THEME_.*",
|
||||
"NODE_.*",
|
||||
|
@ -517,8 +517,8 @@ mod bindings {
|
|||
"StyleAnimationValue", // pulls in a whole bunch of stuff we don't need in the bindings
|
||||
];
|
||||
let blacklist = [
|
||||
".*_char_traits",
|
||||
".*_incompatible_char_type",
|
||||
".*char_traits",
|
||||
".*incompatible_char_type",
|
||||
];
|
||||
|
||||
struct MappedGenericType {
|
||||
|
|
|
@ -2081,7 +2081,7 @@ ${helpers.single_keyword_system("font-variant-position",
|
|||
|
||||
#[inline]
|
||||
pub fn get_initial_value() -> computed_value::T {
|
||||
::gecko_bindings::structs::NS_MATHML_DEFAULT_SCRIPT_SIZE_MULTIPLIER
|
||||
::gecko_bindings::structs::NS_MATHML_DEFAULT_SCRIPT_SIZE_MULTIPLIER as f32
|
||||
}
|
||||
|
||||
pub fn parse(_context: &ParserContext, _input: &mut Parser) -> Result<SpecifiedValue, ()> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue