Skip to content

Commit 8d2c69a

Browse files
New rule layout.repr.c.struct.align-empty
1 parent 92ba1b7 commit 8d2c69a

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/type-layout.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,9 @@ r[layout.repr.c.struct]
200200
r[layout.repr.c.struct.align]
201201
The alignment of the struct is the alignment of the most-aligned field in it.
202202

203+
r[layout.repr.c.struct.align-empty]
204+
The alignment of a struct with no fields is 1.
205+
203206
r[layout.repr.c.struct.size-field-offset]
204207
The size and offset of fields is determined by the following algorithm.
205208

0 commit comments

Comments
 (0)