aboutsummaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
Diffstat (limited to 'components')
-rw-r--r--components/layout/wrapper.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs
index 5ad91dbcbc0..40b362980e2 100644
--- a/components/layout/wrapper.rs
+++ b/components/layout/wrapper.rs
@@ -975,8 +975,9 @@ pub trait ThreadSafeLayoutNode<'ln> : Clone + Copy + Sized {
fn get_colspan(&self) -> u32;
}
-// These can violate the thread-safety and therefore are not public.
-trait DangerousThreadSafeLayoutNode<'ln> : ThreadSafeLayoutNode<'ln> {
+// This trait is only public so that it can be implemented by the gecko wrapper.
+// It can be used to violate thread-safety, so don't use it elsewhere in layout!
+pub trait DangerousThreadSafeLayoutNode<'ln> : ThreadSafeLayoutNode<'ln> {
unsafe fn dangerous_first_child(&self) -> Option<Self>;
unsafe fn dangerous_next_sibling(&self) -> Option<Self>;
}