[fpc-devel] Sets > 256

Frederic Da Vitoria davitofrg at gmail.com
Thu Oct 15 15:47:05 CEST 2015


2015-10-15 14:58 GMT+02:00 DaWorm <daworm at gmail.com>:

> On Wed, Oct 14, 2015 at 5:36 AM, Michael Schnell <mschnell at lumino.de>
> wrote:
>
>> (Not hitchhiking the other thread...)
>>
>> On 13/10/15 19:59, Mohsen wrote:
>>
>>>
>>> Pascal sets can only contain values/enumerations whose ordinal value is
>>> <= 255.
>>>
>> As currently new language features are discussed I would vote to drop (or
>> relax to some K ) this limitation. This would not break any existing code.
>>
>>
> What if someone is storing a set in a file, or a stream?  Old version
> saves it, new version reads it, and all of the sudden the data isn't in the
> same format.
>

Yes, this would be a problem. But wouldn't this be an acceptable price for
the improvement? After all, similar things happen with integers, which
don't always mean the same thing, reals which changed format at least once
in TP/Delphi's history, strings... Sure, we could stick with 256 elements
sets, 16 bits integers, 255 characters strings, but we'd lose a lot of
possibilities, wouldn't we?

-- 
Frederic Da Vitoria
(davitof)

Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20151015/a7feb289/attachment.html>


More information about the fpc-devel mailing list