[Lazarus] dynamic string proposal

Mattias Gaertner nc-gaertnma at netcologne.de
Wed Aug 16 18:24:57 CEST 2017


On Wed, 16 Aug 2017 18:06:36 +0200
Michael Schnell via Lazarus <lazarus at lists.lazarus-ide.org> wrote:

>[...]
> The only difference to the current status is that with the "dynamic" 
> string brand the content of the "bytes per element" field is not 
> predefined by the variable declaration but can change when something is 
> assigned to that (additional) brand of string variables (I feel that 
> this is clearly stated in the paper). Hence for that (additional) brand 
> of string variables the compiler needs to generate code to read this 
> field when implementing the built-in functions.

This "dynamicstring" sounds like Rawbytestring times two. Any function
accessing the inner chars of a "dynamicstring" has to handle
Rawbytestring codepages and unicodestring and array of byte/word/dword.
If this is the price for avoiding some conversions, many programmers
will become unhappy.
Michael, please tell me your proposal has some serious advantages. I
don't see them.

Mattias



More information about the Lazarus mailing list