mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Update rustc to 00b112c45a604fa6f4b59af2a40c9deeadfdb7c6/rustc-1.0.0-dev.
This commit is contained in:
parent
ff8cbff810
commit
95fc29fa0d
255 changed files with 3550 additions and 3362 deletions
|
@ -12,15 +12,18 @@
|
|||
//! - `#[dom_struct]` : Implies `#[privatize]`,`#[jstraceable]`, and `#[must_root]`.
|
||||
//! Use this for structs that correspond to a DOM type
|
||||
|
||||
#![feature(macro_rules, plugin_registrar, quote, phase)]
|
||||
#![feature(plugin_registrar, quote, plugin, box_syntax)]
|
||||
|
||||
#![deny(unused_imports)]
|
||||
#![deny(unused_variables)]
|
||||
#![allow(missing_copy_implementations)]
|
||||
#![allow(unstable)]
|
||||
|
||||
#[phase(plugin,link)]
|
||||
#[plugin]
|
||||
#[macro_use]
|
||||
extern crate syntax;
|
||||
#[phase(plugin, link)]
|
||||
#[plugin]
|
||||
#[macro_use]
|
||||
extern crate rustc;
|
||||
|
||||
use rustc::lint::LintPassObject;
|
||||
|
@ -50,23 +53,3 @@ pub fn plugin_registrar(reg: &mut Registry) {
|
|||
reg.register_lint_pass(box lints::str_to_string::StrToStringPass as LintPassObject);
|
||||
reg.register_lint_pass(box lints::ban::BanPass as LintPassObject);
|
||||
}
|
||||
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! match_ignore_ascii_case {
|
||||
( $value: expr: $( $string: expr => $result: expr ),+ _ => $fallback: expr, ) => {
|
||||
match_ignore_ascii_case! { $value:
|
||||
$( $string => $result ),+
|
||||
_ => $fallback
|
||||
}
|
||||
};
|
||||
( $value: expr: $( $string: expr => $result: expr ),+ _ => $fallback: expr ) => {
|
||||
{
|
||||
use std::ascii::AsciiExt;
|
||||
match $value.as_slice() {
|
||||
$( s if s.eq_ignore_ascii_case($string) => $result, )+
|
||||
_ => $fallback
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue