Le 1 juil. 2015 à 14:42, Torsten Bergmann a écrit :
Christophe Demarey
I tried to create an in-memory file as following: (MemoryFileSystemFile named: 'Foo') writeStreamDo: [ :stream | stream nextPutAll: 'bar' ]
Then I get an improper store into ByteArray. It looks like Character cannot be store in a byte array. I do not know if the bug is on the memory file system part or other. Any idea?
Why do you use MemoryFileSystemFile directly. Usually the FileSystem is the starting point. And there it works:
|fs file| fs := FileSystem memory. file := fs / 'test'. file writeStreamDo: [ :stream | stream nextPutAll: 'bar' ]. fs inspect
The nice thing is that you can now browse the file system and file contents with the new GT Inspector.
oh, perfect. Looks like I was not using the good api. Thanks, Christophe