[erlang-questions] [Erlyaws-list] String Support, The most needed feature
Sun Mar 4 17:46:47 CET 2007
> That said, I do sometimes think perhaps a container
> that has O(1)
> random access time might be nice in Erlang.
If binaries are too much of a hassle, then recall that
tuples have O(1) access and use less memory than lists
(n+1 words rather than 2n). You may have to roll your
own algorithms, I'm afraid. (Too bad we don't have any
generic 'sequence' types and operations, huh?)
To pacify the scripting crowd, one could spend more
time on making regexps more convenient and/or more
general. Or standardize them, e.g., by using the Ruby
syntax or something. In favour of this approach, there
might soon be an infusion of fresh users with Joe's
new book, so this could be as good a time as any to
spruce things up.
However, in general I think the serious string-user
should read Richard O'Keefe's analysis of the issues
made on this list (alas, I didn't bookmark it so
someone will have to dig up the reference). In short,
a bit of sophistication seems to quickly end up with
"strings" that are not arrays of characters and
algorithms that are not regexp evaluation.
Bored stiff? Loosen up...
Download and play hundreds of games for free on Yahoo! Games.
More information about the erlang-questions