- removed ttai_lowleveltypedconstbuilder.queue_addrn(), as we are always

implicitly taking the address of a complex expression in a typed constant
    (you cannot put the contents of another memory location in a typed
    constant)

git-svn-id: trunk@31252 -
This commit is contained in:
Jonas Maebe 2015-07-30 16:58:07 +00:00
parent 0e42559047
commit e93660c170
3 changed files with 3 additions and 16 deletions

View File

@ -343,8 +343,6 @@ type
function queue_subscriptn_multiple_by_name(def: tabstractrecorddef; const fields: array of TIDString): tdef;
{ queue a type conversion operation }
procedure queue_typeconvn(fromdef, todef: tdef); virtual;
{ queue an address taking operation }
procedure queue_addrn(fromdef, todef: tdef); virtual;
{ finalise the queue (so a new one can be created) and flush the
previously queued operations, applying them in reverse order on a...}
{ ... procdef }
@ -1534,11 +1532,6 @@ implementation
{ do nothing }
end;
procedure ttai_typedconstbuilder.queue_addrn(fromdef, todef: tdef);
begin
{ do nothing }
end;
procedure ttai_typedconstbuilder.queue_emit_proc(pd: tprocdef);
begin

View File

@ -313,7 +313,6 @@ implementation
{ pointerdef to the string data array }
dataptrdef:=cpointerdef.getreusable(field.vardef);
queue_init(charptrdef);
queue_addrn(dataptrdef,charptrdef);
queue_subscriptn(strrecdef,field);
queue_emit_asmsym(ll.lab,strrecdef);
end

View File

@ -851,9 +851,7 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
{ we now emit the address of the first element of the array
containing the string data }
ftcb.queue_init(def);
{ address of ... }
ftcb.queue_addrn(def.pointeddef,def);
{ ... the first element ... }
{ the first element ... }
ftcb.queue_vecn(datadef,0);
{ ... of the string array }
ftcb.queue_emit_asmsym(ll,datadef);
@ -888,9 +886,7 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
{ we now emit the address of the first element of the array
containing the string data }
ftcb.queue_init(def);
{ address of ... }
ftcb.queue_addrn(def.pointeddef,def);
{ ... the first element ... }
{ the first element ... }
ftcb.queue_vecn(datadef,0);
{ ... of the string array }
ftcb.queue_emit_asmsym(ll,datadef);
@ -932,7 +928,7 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
ftcb.queue_typeconvn(ttypeconvnode(hp).left.resultdef,hp.resultdef);
end;
addrn :
ftcb.queue_addrn(taddrnode(hp).left.resultdef,hp.resultdef);
{ nothing, is implicit };
else
Message(parser_e_illegal_expression);
end;
@ -1357,7 +1353,6 @@ function get_next_varsym(def: tabstractrecorddef; const SymList:TFPHashObjectLis
{ remove addrn which we also don't need here }
if n.nodetype=addrn then
begin
ftcb.queue_addrn(taddrnode(n).left.resultdef,n.resultdef);
tmpn:=taddrnode(n).left;
taddrnode(n).left:=nil;
n.free;