# Can a source file implicit struct be a packed struct?

**URL:** <https://ziggit.dev/t/can-a-source-file-implicit-struct-be-a-packed-struct/10205>\
**Category:** Help\
**Tags:** language, memory-management\
**Created:** [May 21, 2025, 12:28pm UTC](https://ziggit.dev/t/can-a-source-file-implicit-struct-be-a-packed-struct/10205 "2025-05-21T12:28:03Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![g41797](https://ziggit.dev/user_avatar/ziggit.dev/g41797/32/3339_2.png) [@g41797](https://ziggit.dev/u/g41797)\
**Post date:** [May 21, 2025, 12:41pm UTC](https://ziggit.dev/t/can-a-source-file-implicit-struct-be-a-packed-struct/10205/2 "2025-05-21T12:41:57Z")

</div>

see [packed vs extern clarification](https://github.com/ziglang/zig/issues/12852#issuecomment-1300197546)

and [Clarification about packed structs](https://ziggit.dev/t/clarification-about-packed-structs/1987)

looks like you want to use extern with align

see [example](https://ziggit.dev/t/whats-the-equivalent-of-c-struct-attribute-packed/9364/2)

and don’t worry - you are not alone  
i also failed in similar case 😂

---

_[View the full topic](https://ziggit.dev/t/can-a-source-file-implicit-struct-be-a-packed-struct/10205)._
