Add some size assertions

This commit is contained in:
Lukas Wirth 2024-01-26 10:43:25 +01:00
parent d8ef6c24cc
commit 5a343415e8
13 changed files with 194 additions and 198 deletions

View file

@ -15,6 +15,7 @@ use crate::{
use base_db::CrateId;
use smallvec::SmallVec;
use span::SyntaxContextId;
use stdx::assert_eq_size;
use syntax::{ast, AstNode};
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
@ -22,6 +23,7 @@ pub struct ModPath {
pub kind: PathKind,
segments: SmallVec<[Name; 1]>,
}
assert_eq_size!(ModPath, 40);
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct UnescapedModPath<'a>(&'a ModPath);