[fpc-devel] RFC: Support for new type "tuple" v0.1

Sven Barth pascaldragon at googlemail.com
Sat Jan 26 19:28:27 CET 2013


On 26.01.2013 19:20, Marco van de Voort wrote:
> In our previous episode, Sven Barth said:
>>> In a quick read, I cannot see any limitations to the type used for
>>> a tuple-element except that it behaves like "file of..."
>>>
>>> So that would mean a record type (or other non variant compatible type)
>>> would qualify?
>>
>> Whether there should be restrictions of types could be added to the open
>> issues as I'd want to have at least equality operators working for
>> tuples and thus we need to think about something for records... (as a
>> solution one could require that a "=" operator for records must be in scope)
>>
>> But without that problem in mind I had wanted to allow every type for
>> tuple elements (even tuples).
>>
>> Out of curiosity: Do you see this positive or negative?
>
> To be frank, I'm not interested in the whole shebang. It reeks too much like
> first wanting an extension, and then thinking of one.
>
> But, like you, when it is being done, it should be done decent, and IMHO
> using array of variant (or tvarrec) as implementation vehicle is limiting
> the feature too much. Either good, or not.

Ah, this is how you meant it.

As I've written in the beginning of the draft I think of tuples more 
like a simplified record type (in terms of compiler implementation, etc).

Regards,
Sven




More information about the fpc-devel mailing list