Streams and Strings

Kent Boortz kent@REDACTED
Sun Jun 30 09:01:59 CEST 2002


"Alex Peake" <apeake@REDACTED> writes:
> Is there any concept of a Stream on a String, or an "in-memory"
> stream in Erlang?
> 
> (Or perhaps string concatenation is much more efficient in Erlang
> than in (many) other languages?)

String concatenation is not more efficient in Erlang than other
languages, like Lisp and Prolog.

I don't know what "Stream on a String" means but one solution used by
for example the GS application is to use "deep strings", i.e. a
concatenation is just a cons

  [String1,String2]

You can send deep strings to ports, the port will flatten it out,

kent



More information about the erlang-questions mailing list