* set an owner for open array defs being created in property declarations, resolves #25769

git-svn-id: trunk@38348 -
This commit is contained in:
florian 2018-02-25 17:36:34 +00:00
parent 451203512b
commit 14cb60e479
4 changed files with 50 additions and 0 deletions

2
.gitattributes vendored
View File

@ -14305,6 +14305,7 @@ tests/webtbf/tw25504.pp svneol=native#text/plain
tests/webtbf/tw2562.pp svneol=native#text/plain
tests/webtbf/tw25622.pp svneol=native#text/plain
tests/webtbf/tw25622a.pp svneol=native#text/plain
tests/webtbf/tw25769.pp svneol=native#text/pascal
tests/webtbf/tw25788.pp svneol=native#text/pascal
tests/webtbf/tw25861.pp svneol=native#text/plain
tests/webtbf/tw25862.pp svneol=native#text/plain
@ -15567,6 +15568,7 @@ tests/webtbs/tw2561.pp svneol=native#text/plain
tests/webtbs/tw25610.pp -text svneol=native#text/plain
tests/webtbs/tw25685.pp svneol=native#text/pascal
tests/webtbs/tw25703.pp svneol=native#text/plain
tests/webtbs/tw25769a.pp svneol=native#text/pascal
tests/webtbs/tw25781.pp svneol=native#text/plain
tests/webtbs/tw25814.pp svneol=native#text/plain
tests/webtbs/tw25869.pp svneol=native#text/plain

View File

@ -415,6 +415,7 @@ implementation
consume(_OF);
{ define range and type of range }
hdef:=carraydef.create(0,-1,s32inttype);
hdef.owner:=astruct.symtable;
{ define field type }
single_type(arraytype,[]);
tarraydef(hdef).elementdef:=arraytype;

23
tests/webtbf/tw25769.pp Normal file
View File

@ -0,0 +1,23 @@
{ %fail }
unit tw25769;
{$mode objfpc}{$H+}
interface
type
TDbgSymbolValue = class(TObject)
protected
function GetMemberCountEx(AIndex: array of Integer): Integer;
public
property MemberCountEx[AIndex: array of Integer]: Integer read GetMemberCountEx;
end;
implementation
function TDbgSymbolValue.GetMemberCountEx(AIndex: Integer): Integer;
begin
end;
end.

24
tests/webtbs/tw25769a.pp Normal file
View File

@ -0,0 +1,24 @@
{ %norun }
unit tw25769a;
{$mode objfpc}{$H+}
interface
type
TDbgSymbolValue = class(TObject)
protected
function GetMemberCountEx(AIndex: array of Integer): Integer;
public
property MemberCountEx[AIndex: array of Integer]: Integer read GetMemberCountEx;
end;
implementation
function TDbgSymbolValue.GetMemberCountEx(AIndex: array of Integer): Integer;
begin
result:=0;
end;
end.