[Lazarus] dynamic string proposal
Mattias Gaertner
nc-gaertnma at netcologne.de
Wed Aug 16 11:51:14 CEST 2017
Starting a new thread for a new topic. It's not that hard.
On Wed, 16 Aug 2017 11:26:46 +0200
Michael Schnell via Lazarus <lazarus at lists.lazarus-ide.org> wrote:
> On 15.08.2017 18:33, Mattias Gaertner via Lazarus wrote:
> > Do you propose a string without the array operator [] ?
> I don't understand what you mean by this.
Every Delphi/FPC type has a bunch of operators. Strings support :=, =, <>, >=, <= and [] for read and write.
When you propose a new string type "dynamicstring" you have to define these operators. Otherwise your proposal is not a string, but just a magic unicorn.
> Of course an appropriate "char" type for each string encoding brand
> could to be provided, hence a "CP_QWord Char" as an alias or a QWord.
There is no QWord codepage. That would be confusing.
> (Please keep in mind that in that paper (as explicitly pointed out)
> "String" is not a synonym for "printable text" but for "sequence of
> similar things". And here of course (at least in a 64 bit system) it's
> extremely appropriate to allow for 64 bit elements. And of course this
> is just a suggestion that could solve a certain class of problems but
> needs a big effort to do and verify the modifications in the compiler
> and the libraries.)
Mattias
More information about the Lazarus
mailing list