View Issue Details

IDProjectCategoryView StatusLast Update
0035809FPCCompilerpublic2019-07-07 09:56
ReporterRyan Joseph Assigned ToTomas Hajny  
Status closedResolutionduplicate 
Product Version3.3.1 
Summary0035809: Invalid array property parameters
DescriptionArray properties can be accessed using a wrong number of parameters by leveraging function overloads. This may be desirable for Delphi mode but should be disallowed in ObjFPC mode.

When this behavior is removed it can be replaced with a proper array property overloads patch (which is pending:
Steps To Reproducefunction GetValue(k0: variant): TJSON; overload;
function GetValue(k0,k1: variant): TJSON; overload;
property Values[key: variant]: TJSON read GetValue; default;

// should work
i := rec[1];

// should *not* work but currently does
i := rec[1, 2];
TagsNo tags attached.
Fixed in Revision
Attached Files


duplicate of 0028949 confirmed Compiler does not check if array property parameters match 


Ryan Joseph

2019-07-06 22:13

reporter   ~0117102

Last edited: 2019-07-07 09:55

View 2 revisions

Oops, this is a duplicate of 0028949. please close.

Tomas Hajny

2019-07-07 09:56

manager   ~0117103

Duplicate as suggested by the reporter.

Issue History

Date Modified Username Field Change
2019-07-06 20:02 Ryan Joseph New Issue
2019-07-06 22:13 Ryan Joseph Note Added: 0117102
2019-07-07 09:55 Tomas Hajny Note Edited: 0117102 View Revisions
2019-07-07 09:55 Tomas Hajny Relationship added duplicate of 0028949
2019-07-07 09:56 Tomas Hajny Assigned To => Tomas Hajny
2019-07-07 09:56 Tomas Hajny Status new => closed
2019-07-07 09:56 Tomas Hajny Resolution open => duplicate
2019-07-07 09:56 Tomas Hajny FPCTarget => -
2019-07-07 09:56 Tomas Hajny Note Added: 0117103