Are strings in Erlang rather inefficient? Or does the memory usage or string performance not matter in practice?
I have always ignored anything related to Erlang because I dislike the idea of a language that lacks an efficient string representation . . . even though I have spent over a decade using JavaScript! (so maybe I don’t actually care?)
There are binaries and strings. Binaries is what are used as efficient "strings" most often these days. Binaries allow matching, even building bitstrings (binary strings not ending on an 8 bit boundary). Even more interesting, strings and binaries can be combined in iolists, which is an arbitrarily nested or combined list of binaries or other lists. Those can be used for efficient IO and IO drivers know how to emit or consume those.
I have always ignored anything related to Erlang because I dislike the idea of a language that lacks an efficient string representation . . . even though I have spent over a decade using JavaScript! (so maybe I don’t actually care?)