summaryrefslogtreecommitdiff
path: root/pidl/lib/Parse/Pidl/NDR.pm
diff options
context:
space:
mode:
Diffstat (limited to 'pidl/lib/Parse/Pidl/NDR.pm')
-rw-r--r--pidl/lib/Parse/Pidl/NDR.pm11
1 files changed, 9 insertions, 2 deletions
diff --git a/pidl/lib/Parse/Pidl/NDR.pm b/pidl/lib/Parse/Pidl/NDR.pm
index 7aebed0fe2..4f2578e72e 100644
--- a/pidl/lib/Parse/Pidl/NDR.pm
+++ b/pidl/lib/Parse/Pidl/NDR.pm
@@ -509,7 +509,8 @@ sub ParseUnion($$)
ELEMENTS => undef,
PROPERTIES => $e->{PROPERTIES},
HAS_DEFAULT => $hasdefault,
- ORIGINAL => $e
+ ORIGINAL => $e,
+ ALIGN => undef
} unless defined($e->{ELEMENTS});
CheckPointerTypes($e, $pointer_default);
@@ -533,6 +534,11 @@ sub ParseUnion($$)
push @elements, $t;
}
+ my $align = undef;
+ if ($e->{NAME}) {
+ $align = align_type($e->{NAME});
+ }
+
return {
TYPE => "UNION",
NAME => $e->{NAME},
@@ -540,7 +546,8 @@ sub ParseUnion($$)
ELEMENTS => \@elements,
PROPERTIES => $e->{PROPERTIES},
HAS_DEFAULT => $hasdefault,
- ORIGINAL => $e
+ ORIGINAL => $e,
+ ALIGN => $align
};
}