Update bitflags to 1.0 in every servo crate

It still needs dependencies update to remove all the other bitflags
versions.
This commit is contained in:
Bastien Orivel 2017-10-09 17:03:40 +02:00
parent 4cf2ce66fc
commit e8e2d0a4b2
142 changed files with 1685 additions and 1635 deletions

View file

@ -15,7 +15,7 @@ use properties::longhands::transition_timing_function::single_value::SpecifiedVa
use servo_arc::Arc;
use shared_lock::{DeepCloneParams, DeepCloneWithLock, SharedRwLock, SharedRwLockReadGuard, Locked, ToCssWithGuard};
use std::fmt;
use style_traits::{PARSING_MODE_DEFAULT, ToCss, ParseError, StyleParseErrorKind};
use style_traits::{ParsingMode, ToCss, ParseError, StyleParseErrorKind};
use stylesheets::{CssRuleType, StylesheetContents};
use stylesheets::rule_parser::VendorPrefix;
use values::{KeyframesName, serialize_percentage};
@ -218,7 +218,7 @@ impl Keyframe {
parent_stylesheet_contents.origin,
&url_data,
Some(CssRuleType::Keyframe),
PARSING_MODE_DEFAULT,
ParsingMode::DEFAULT,
parent_stylesheet_contents.quirks_mode
);
let error_context = ParserErrorContext { error_reporter: &error_reporter };

View file

@ -31,7 +31,7 @@ use parser::{ParserContext, ParserErrorContext};
use servo_arc::Arc;
use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard, ToCssWithGuard};
use std::fmt;
use style_traits::PARSING_MODE_DEFAULT;
use style_traits::ParsingMode;
pub use self::counter_style_rule::CounterStyleRule;
pub use self::document_rule::DocumentRule;
@ -241,7 +241,7 @@ impl CssRule {
parent_stylesheet_contents.origin,
&url_data,
None,
PARSING_MODE_DEFAULT,
ParsingMode::DEFAULT,
parent_stylesheet_contents.quirks_mode,
);

View file

@ -41,13 +41,13 @@ impl Origin {
bitflags! {
/// A set of origins. This is equivalent to Gecko's OriginFlags.
#[cfg_attr(feature = "servo", derive(MallocSizeOf))]
pub flags OriginSet: u8 {
pub struct OriginSet: u8 {
/// <https://drafts.csswg.org/css-cascade/#cascade-origin-user-agent>
const ORIGIN_USER_AGENT = Origin::UserAgent as u8,
const ORIGIN_USER_AGENT = Origin::UserAgent as u8;
/// <https://drafts.csswg.org/css-cascade/#cascade-origin-user>
const ORIGIN_USER = Origin::User as u8,
const ORIGIN_USER = Origin::User as u8;
/// <https://drafts.csswg.org/css-cascade/#cascade-origin-author>
const ORIGIN_AUTHOR = Origin::Author as u8,
const ORIGIN_AUTHOR = Origin::Author as u8;
}
}

View file

@ -18,7 +18,7 @@ use servo_arc::Arc;
use shared_lock::{DeepCloneParams, DeepCloneWithLock, Locked, SharedRwLock, SharedRwLockReadGuard};
use std::mem;
use std::sync::atomic::{AtomicBool, Ordering};
use style_traits::PARSING_MODE_DEFAULT;
use style_traits::ParsingMode;
use stylesheets::{CssRule, CssRules, Origin, UrlExtraData};
use stylesheets::loader::StylesheetLoader;
use stylesheets::rule_parser::{State, TopLevelRuleParser};
@ -364,7 +364,7 @@ impl Stylesheet {
origin,
url_data,
None,
PARSING_MODE_DEFAULT,
ParsingMode::DEFAULT,
quirks_mode
);
let error_context = ParserErrorContext { error_reporter };