Subject: Re: [boost] [string] proposal
From: Artyom (artyomtnk_at_[hidden])
Date: 2011-01-29 10:44:28
> >>> You know what...
> >>> I'd really like your data structure if you were not
> >>> calling it string but rather bytes chunk or immutable
> >>> bytes array.
> >>> What you are suggesting has noting to do with text,
> >>> and I don't understand how do you fail to see this.
> >> I don't know if you're not a native English speaker or whether you
> >> just really think strings are just for text.
> > First of all, in programming languages (at least the 20 or so that I master
>and in which I have developed software professionally), the notion of 'string'
>is that of text (and in some languages 'string' is nothing more than an alias
>for an array/vector of characters.)
> > But your intention is to use your "string" for other types of elements,
>i.e., to be what is called a 'vector' in C++, albeit immutable. No?
> I wonder where you got that notion. I framed the discussion around my
> definition of `string` to be a sequence. In that context (in an
> earlier post) I was basically saying "a string is a data structure for
> holding things, [FOR EXAMPLE] a string of events, a string of
> characters, ..." just to frame the definition properly and identify
> that I was talking about a data structure.
- Java String - one meaning text, UTF-16 encoded
- C# string - one meaning text, UTF-16 encoded
- C++/GTKmm ustring - one meaning text, UTF-8 encoded
- C++/Qt QString - one meaning text, UTF-16 encoded
- C++/wxWidgets wxString - one meaning text, Unicode (don't remember encoding
- Vala string - text UTF-8 encoded
- Python 3 str[ing] - text UTF-16 ot UTF-32 encoded
Is this clear enough?
When you say string you mean TEXT not more not less.
And yes in C++ you can store arbitrary date in char buffers
or in std::string, but this does not change the meaning
of string word - it means "text"
Don't try to reinvent the meaning of string word in CS context.
It is not about English, it is about concept.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk