Skip to main content

layout

Function layout 

Source
pub fn layout(
    types: &Types,
    id: TypeId,
    target: &TargetInfo,
) -> Result<Layout, LayoutError>
Expand description

The size and alignment of id on target.

ยงErrors

LayoutError when the type has no layout, which is a normal answer rather than a bug: sizeof an incomplete type is a diagnostic, and the caller is the one holding the span.