[fpc-devel] [] property overloads
Michael Van Canneyt
michael at freepascal.org
Tue Jul 2 09:27:04 CEST 2019
On Tue, 2 Jul 2019, Ondrej Pokorny wrote:
> On 02.07.2019 09:10, Michael Van Canneyt wrote:
>> I had a quick peek in the compiler sources.
>>
>> In pexpr.pas, before processing the [, the compiler calls this:
>>
>> { we need the resultdef }
>> do_typecheckpass_changed(p1,nodechanged);
>>
>> In my opinion, this routine will/should error out if there are 2 symbols
>> called 'StringArray' : one with type 'array property' and one with
>> type 'enumerator'.
>
> This code is never executed for an array property. The "[" for an array
> property is processed directly in handle_propertysym:
Well, I think you are mistaken because I think the code I pointed to is executed
before handle_propertysym is called. But I will not argue the point, you may
still be right, it just costs me too much time to trace this.
So I still think the compiler people have the final word.
Michael.
More information about the fpc-devel
mailing list