Re: type string

new topic     » topic index » view thread      » older message » newer message

> Now, I know that Euphoria allows fp values for its string chars, but is it
> *really* necessary for the string() type to allow them, too? It's the
> biggest speed-killer of the bunch (string6i above).

Sometimes it scares me how often people conclude something based upon too little
knowledge, especially knowing I'm one of those
people.
What if, in a string all values would be stored as bytes ? It would be about 2
to 4 times slower to read or write a value. It
would be much much slower when resizing the string. That's due to the 32-bit
machine integer architecture of today's chips. The
only speed loss with Euphoria's sequence, is that all elements of a sequence are
of type object. Off course I know they the
interpreter couldn't spit through my type-function and find out which type is
allowed for which element. But then again, I would
be starting up the structures discussion. (you know that discussion, where many
dismissed structures because they were thinking
such a  structure-datatype would inherit the same indynamic-resizable behavior
as any datatype in C/Basic) rather than the same
dynamic and flexible behaviors of sequences. And therefor claimed it would not
work. Oh well..

Ralf

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu