aboutsummaryrefslogtreecommitdiffstats
path: root/components/script_plugins
diff options
context:
space:
mode:
authorKunal Mohan <kunalmohan99@gmail.com>2020-01-07 13:27:19 +0530
committerKunal Mohan <kunalmohan99@gmail.com>2020-01-08 09:44:41 +0530
commit02c1612cb0dd5a74deb33c9c31d89ded2b50d0a9 (patch)
treeb80ca8ca874d2e4b30b579795292c168daccbb39 /components/script_plugins
parentbd636b0e6c4f124281ce9206eedd7f60ba4ed475 (diff)
downloadservo-02c1612cb0dd5a74deb33c9c31d89ded2b50d0a9.tar.gz
servo-02c1612cb0dd5a74deb33c9c31d89ded2b50d0a9.zip
Add accountable-refcell as optional build time feature
Diffstat (limited to 'components/script_plugins')
-rw-r--r--components/script_plugins/lib.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/components/script_plugins/lib.rs b/components/script_plugins/lib.rs
index f686f64f6fe..0bd43021a2e 100644
--- a/components/script_plugins/lib.rs
+++ b/components/script_plugins/lib.rs
@@ -125,6 +125,8 @@ fn is_unrooted_ty(sym: &Symbols, cx: &LateContext, ty: &ty::TyS, in_new_function
match_def_path(cx, did.did, &[sym::core, sym.cell, sym.RefMut]) ||
match_def_path(cx, did.did, &[sym::core, sym.slice, sym.Iter]) ||
match_def_path(cx, did.did, &[sym::core, sym.slice, sym.IterMut]) ||
+ match_def_path(cx, did.did, &[sym.accountable_refcell, sym.Ref]) ||
+ match_def_path(cx, did.did, &[sym.accountable_refcell, sym.RefMut]) ||
match_def_path(
cx,
did.did,
@@ -175,6 +177,7 @@ fn is_unrooted_ty(sym: &Symbols, cx: &LateContext, ty: &ty::TyS, in_new_function
ty::Ref(..) => false, // don't recurse down &ptrs
ty::RawPtr(..) => false, // don't recurse down *ptrs
ty::FnDef(..) | ty::FnPtr(_) => false,
+
_ => true,
}
});
@@ -412,6 +415,7 @@ symbols! {
rc
Rc
cell
+ accountable_refcell
Ref
RefMut
slice