aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/macros.rs
diff options
context:
space:
mode:
authorbors-servo <metajack+bors@gmail.com>2015-08-27 09:38:48 -0600
committerbors-servo <metajack+bors@gmail.com>2015-08-27 09:38:48 -0600
commit909429702972d53bf02dfe9a4aa93ea0cb588cf4 (patch)
tree1a64c15ec378b98ae445257c1c7177af65afee6b /components/script/dom/macros.rs
parent2d704312685249c20fa71d983094fc4e689bc5ff (diff)
parent2a028f66a2e7ab56094cf856ebdc20bc49ab7d4d (diff)
downloadservo-909429702972d53bf02dfe9a4aa93ea0cb588cf4.tar.gz
servo-909429702972d53bf02dfe9a4aa93ea0cb588cf4.zip
Auto merge of #7401 - nox:rm-helpers, r=Manishearth
Remove helper traits Now that `JSRef<T>` is gone, there is no need to have helper traits. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7401) <!-- Reviewable:end -->
Diffstat (limited to 'components/script/dom/macros.rs')
-rw-r--r--components/script/dom/macros.rs12
1 files changed, 0 insertions, 12 deletions
diff --git a/components/script/dom/macros.rs b/components/script/dom/macros.rs
index c2becf46c48..1aab4027b64 100644
--- a/components/script/dom/macros.rs
+++ b/components/script/dom/macros.rs
@@ -7,7 +7,6 @@ macro_rules! make_getter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self) -> DOMString {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
element.get_string_attribute(&Atom::from_slice($htmlname))
@@ -23,7 +22,6 @@ macro_rules! make_bool_getter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self) -> bool {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not runtime.
@@ -40,7 +38,6 @@ macro_rules! make_uint_getter(
($attr:ident, $htmlname:expr, $default:expr) => (
fn $attr(self) -> u32 {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not runtime.
@@ -60,7 +57,6 @@ macro_rules! make_url_getter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self) -> DOMString {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not runtime.
@@ -78,8 +74,6 @@ macro_rules! make_url_or_base_getter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self) -> DOMString {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
- use dom::window::WindowHelpers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
let url = element.get_url_attribute(&Atom::from_slice($htmlname));
@@ -101,7 +95,6 @@ macro_rules! make_enumerated_getter(
( $attr:ident, $htmlname:expr, $default:expr, $(($choices: pat))|+) => (
fn $attr(self) -> DOMString {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use std::ascii::AsciiExt;
use std::borrow::ToOwned;
use string_cache::Atom;
@@ -127,7 +120,6 @@ macro_rules! make_setter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self, value: DOMString) {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not at runtime.
@@ -141,7 +133,6 @@ macro_rules! make_bool_setter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self, value: bool) {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not at runtime.
@@ -155,7 +146,6 @@ macro_rules! make_uint_setter(
($attr:ident, $htmlname:expr, $default:expr) => (
fn $attr(self, value: u32) {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let value = if value > 2147483647 {
$default
@@ -177,7 +167,6 @@ macro_rules! make_limited_uint_setter(
($attr:ident, $htmlname:expr, $default:expr) => (
fn $attr(self, value: u32) -> $crate::dom::bindings::error::ErrorResult {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let value = if value == 0 {
return Err($crate::dom::bindings::error::Error::IndexSize);
@@ -205,7 +194,6 @@ macro_rules! make_atomic_setter(
( $attr:ident, $htmlname:expr ) => (
fn $attr(self, value: DOMString) {
use dom::bindings::codegen::InheritTypes::ElementCast;
- use dom::element::AttributeHandlers;
use string_cache::Atom;
let element = ElementCast::from_ref(self);
// FIXME(pcwalton): Do this at compile time, not at runtime.