aboutsummaryrefslogtreecommitdiffstats
path: root/components/style/rule_tree/mod.rs
diff options
context:
space:
mode:
authorAnthony Ramine <nox@nox.paris>2020-04-16 16:41:01 +0200
committerAnthony Ramine <nox@nox.paris>2020-04-17 12:41:10 +0200
commita30da7ad8e75dc9c599af92e297650d15cbead07 (patch)
tree3a335f8a14df9e5a6aaa23f623f9b1332b91e341 /components/style/rule_tree/mod.rs
parentbc4e2942bff4c2998b5c2a36144b168b02e884b3 (diff)
downloadservo-a30da7ad8e75dc9c599af92e297650d15cbead07.tar.gz
servo-a30da7ad8e75dc9c599af92e297650d15cbead07.zip
Introduce a new type UnsafeBox<T> in the rule tree
This lets us rely less on raw pointers, thus better tracking the lifetime of the rule node values while dropping strong references etc.
Diffstat (limited to 'components/style/rule_tree/mod.rs')
-rw-r--r--components/style/rule_tree/mod.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/components/style/rule_tree/mod.rs b/components/style/rule_tree/mod.rs
index 41f87935df4..2af7989ca4c 100644
--- a/components/style/rule_tree/mod.rs
+++ b/components/style/rule_tree/mod.rs
@@ -2,6 +2,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
+#![deny(unsafe_code)]
+
//! The rule tree.
use crate::applicable_declarations::ApplicableDeclarationList;
@@ -15,6 +17,7 @@ mod core;
mod level;
mod map;
mod source;
+mod unsafe_box;
pub use self::core::{RuleTree, StrongRuleNode};
pub use self::level::{CascadeLevel, ShadowCascadeOrder};