diff options
Diffstat (limited to 'gcc/d/modules.cc')
-rw-r--r-- | gcc/d/modules.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/d/modules.cc b/gcc/d/modules.cc index a1fc534..e9bd441 100644 --- a/gcc/d/modules.cc +++ b/gcc/d/modules.cc @@ -534,7 +534,9 @@ layout_moduleinfo_fields (Module *decl, tree type) layout_moduleinfo_field (make_array_type (Type::tchar, namelen), type, offset); - finish_aggregate_type (offset, 1, type, NULL); + size_t alignsize = MAX (TYPE_ALIGN_UNIT (type), + TYPE_ALIGN_UNIT (ptr_type_node)); + finish_aggregate_type (offset, alignsize, type, NULL); return type; } |