Strings are immutable so I doubt this is supported. You can use: IOBuffer([*size*]) → IOBuffer <http://docs.julialang.org/en/release-0.1/stdlib/base/#Base.IOBuffer>
Create an in-memory I/O stream, optionally specifying how much initial space is needed. You can also do string interpolation: *julia> **a = "foo"* *"foo"* *julia> **b = "bar"* *"bar"* *julia> **"$a$b"* *"foobar"* On Sunday, November 9, 2014 10:08:10 AM UTC-5, Tamas Papp wrote: > > Hi, > > I am looking for the Julia equivalent of the Common Lisp macro/idiom > WITH-OUTPUT-TO-STRING, eg > > (with-output-to-string (s) > (format s "foo") > (format s "bar")) ; => "foobar" > > I looked at the Text I/O section of the manual but didn't find anything > similar. > > If this does not exist, a few hints on how to accumulate strings in an > IOstream would point me in the right direction, I think I can write the > macro part. > > Best, > > Tamas >
