+ support procvardefs (address only) in i8086's hlcgcpu.getaddressregister; this

fixes e.g. obtaining the address of a method in i8086 far code memory models
  after r32414

git-svn-id: trunk@32562 -
This commit is contained in:
nickysn 2015-12-01 15:58:11 +00:00
parent 3c32f814de
commit 1e33924f73

View File

@ -248,6 +248,15 @@ implementation
if is_implicit_pointer_object_type(size) or is_implicit_array_pointer(size) then
size:=voidpointertype;
{ procvars follow the default code pointer size for the current memory model }
if size.typ=procvardef then
if ((po_methodpointer in tprocvardef(size).procoptions) or
is_nested_pd(tprocvardef(size))) and
not(po_addressonly in tprocvardef(size).procoptions) then
internalerror(2015120101)
else
size:=voidcodepointertype;
if is_farpointer(size) or is_hugepointer(size) then
Result:=cg.getintregister(list,OS_32)
else