aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bindings/utils.rs
diff options
context:
space:
mode:
authorJosh Matthews <josh@joshmatthews.net>2016-03-23 19:00:32 -0400
committerJosh Matthews <josh@joshmatthews.net>2016-05-02 14:32:55 -0400
commit88059acd7efb4dceda48ec305528a247fd520c4f (patch)
tree64db678fba232e0bac029c926bacf298e602eb65 /components/script/dom/bindings/utils.rs
parent693d31d4edd0eaaaf01249f6eacd9b14956430d7 (diff)
downloadservo-88059acd7efb4dceda48ec305528a247fd520c4f.tar.gz
servo-88059acd7efb4dceda48ec305528a247fd520c4f.zip
Start generating arrays of specs for easier implementation of preference checks.
Diffstat (limited to 'components/script/dom/bindings/utils.rs')
-rw-r--r--components/script/dom/bindings/utils.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/components/script/dom/bindings/utils.rs b/components/script/dom/bindings/utils.rs
index 9302bb40a09..1e2cf5c40f6 100644
--- a/components/script/dom/bindings/utils.rs
+++ b/components/script/dom/bindings/utils.rs
@@ -557,3 +557,9 @@ unsafe extern "C" fn instance_class_has_proto_at_depth(clasp: *const js::jsapi::
pub const DOM_CALLBACKS: DOMCallbacks = DOMCallbacks {
instanceClassMatchesProto: Some(instance_class_has_proto_at_depth),
};
+
+#[allow(missing_docs)]
+pub struct Prefable<T: 'static> {
+ pub pref: Option<&'static str>,
+ pub specs: &'static [T]
+}