mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-11 22:06:40 +02:00
+ 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:
parent
3c32f814de
commit
1e33924f73
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user