mirror of
https://github.com/servo/servo.git
synced 2025-08-25 23:28:21 +01:00
Made PipelineId non-zero, so optional ids take no more space.
This commit is contained in:
parent
a0afa66dbe
commit
6754b2834f
11 changed files with 79 additions and 33 deletions
14
tests/unit/msg/size_of.rs
Normal file
14
tests/unit/msg/size_of.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use msg::constellation_msg::BrowsingContextId;
|
||||
use msg::constellation_msg::PipelineId;
|
||||
use msg::constellation_msg::TopLevelBrowsingContextId;
|
||||
|
||||
size_of_test!(test_size_of_pipeline_id, PipelineId, 8);
|
||||
size_of_test!(test_size_of_optional_pipeline_id, Option<PipelineId>, 8);
|
||||
size_of_test!(test_size_of_browsing_context_id, BrowsingContextId, 8);
|
||||
size_of_test!(test_size_of_optional_browsing_context_id, Option<BrowsingContextId>, 8);
|
||||
size_of_test!(test_size_of_top_level_browsing_context_id, TopLevelBrowsingContextId, 8);
|
||||
size_of_test!(test_size_of_top_level_optional_browsing_context_id, Option<TopLevelBrowsingContextId>, 8);
|
Loading…
Add table
Add a link
Reference in a new issue