mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-13 07:34:28 +02:00
* allow absolutes on open arrays (use of this is doubtful though), resolves #41147
This commit is contained in:
parent
637fa74c5c
commit
29b3b09251
@ -4667,6 +4667,7 @@ implementation
|
||||
if result and
|
||||
{ don't try to check the size of an open array }
|
||||
(is_open_array(resultdef) or
|
||||
is_open_array(left.resultdef) or
|
||||
(resultdef.size<left.resultdef.size) or
|
||||
((resultdef.size=left.resultdef.size) and
|
||||
(left.resultdef.size<sizeof(aint)) and
|
||||
|
@ -23,7 +23,7 @@ unit aoptx86;
|
||||
|
||||
{$i fpcdefs.inc}
|
||||
|
||||
{$define DEBUG_AOPTCPU}
|
||||
{ $define DEBUG_AOPTCPU}
|
||||
|
||||
{$ifdef EXTDEBUG}
|
||||
{$define DEBUG_AOPTCPU}
|
||||
|
15
tests/webtbs/tw41147.pp
Normal file
15
tests/webtbs/tw41147.pp
Normal file
@ -0,0 +1,15 @@
|
||||
{ %norun }
|
||||
{ the code makes no sense, but it should compile }
|
||||
{$MODE OBJFPC}
|
||||
{$MODESWITCH ADVANCEDRECORDS+}
|
||||
program test;
|
||||
|
||||
procedure Resolve(out Unsigned: array of QWord);
|
||||
var
|
||||
Signed: array of Int64 absolute Unsigned;
|
||||
begin
|
||||
SetLength(Signed, 0);
|
||||
end;
|
||||
|
||||
begin
|
||||
end.
|
Loading…
Reference in New Issue
Block a user