aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout/table.rs
diff options
context:
space:
mode:
authorSimon Sapin <simon.sapin@exyr.org>2017-10-14 00:03:57 +0200
committerSimon Sapin <simon.sapin@exyr.org>2017-10-14 00:03:57 +0200
commitb505c9e94817847e19f22854b2ee4258f66f18d2 (patch)
treefad6d01d0f273b36823f70bda152310fa12f7a28 /components/layout/table.rs
parent4c5d6fd8345f301be4aafe2dba71cdf2de0ab01e (diff)
downloadservo-b505c9e94817847e19f22854b2ee4258f66f18d2.tar.gz
servo-b505c9e94817847e19f22854b2ee4258f66f18d2.zip
Introduce an unsafe HasBaseFlow trait for base()/base_mut() casts.
Diffstat (limited to 'components/layout/table.rs')
-rw-r--r--components/layout/table.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/components/layout/table.rs b/components/layout/table.rs
index a0c7c69ce85..7009e4ec60b 100644
--- a/components/layout/table.rs
+++ b/components/layout/table.rs
@@ -34,10 +34,14 @@ use table_row::{self, CellIntrinsicInlineSize, CollapsedBorder, CollapsedBorderP
use table_row::TableRowFlow;
use table_wrapper::TableLayout;
+#[allow(unsafe_code)]
+unsafe impl ::flow::HasBaseFlow for TableFlow {}
+
/// A table flow corresponded to the table's internal table fragment under a table wrapper flow.
/// The properties `position`, `float`, and `margin-*` are used on the table wrapper fragment,
/// not table fragment per CSS 2.1 § 10.5.
#[derive(Serialize)]
+#[repr(C)]
pub struct TableFlow {
pub block_flow: BlockFlow,