* don't emit padding bytes if there was an error parsing a typed constant

record

git-svn-id: branches/hlcgllvm@28758 -
This commit is contained in:
Jonas Maebe 2014-10-06 20:53:33 +00:00
parent 0def3629cc
commit bdfb6d81e5

View File

@ -1621,6 +1621,8 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
) then
Message1(parser_w_skipped_fields_after,sorg);
if not error then
begin
if not(is_packed) then
fillbytes:=def.size-recoffset
else
@ -1631,6 +1633,7 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
end;
for i:=1 to fillbytes do
ftcb.emit_tai(Tai_const.Create_8bit(0),u8inttype);
end;
ftcb.maybe_end_aggregate(def);
consume(_RKLAMMER);