Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 9
    I honestly didn't think I'd see something useful come out of this question. Wasn't aware of that gcc option (and now I'm hopign clang has it as well). Thanks for teaching me something. tick. Commented Jun 25, 2019 at 20:53
  • 1
    @WhozCraig Yes, clang also has this option (it even has the same name). It's very helpful (at least for me) when dealing with the "rearrangement problem". It's a bummer that (at least for now) I haven't found an automated solution. Commented Jun 26, 2019 at 17:57
  • Are there any remotely-modern platforms in which placing types in the order double, [unsigned] long long, [i]int64_t, int64_t, pointers, long, float, int32_t, int, int16_t, short, char, would not yield optimal alignment? Commented Jun 29, 2019 at 17:38
  • Your links to eel.is expire as the draft standard evolves. It would be useful to link to a finalized document. See here. Example: [class.mem]/19. Commented Apr 25, 2023 at 15:03