[Pharo-project] Character and binary streams
Hi all, while working on the unicode cleanup I ran into the current implementation of Character>>storeBinaryOn: aStream "Store the receiver on a binary (file) stream" value < 256 ifTrue:[aStream basicNextPut: self] ifFalse:[Stream nextInt32Put: value]. Me thinks this is pretty useless, as there is no way to read the binary stream again unless you would know at which indices you stored one or four byte characters. The only place where this method is called from text converters writing to binary streams and can only happen, when the converter encounters a unicode character that has now corresponding mapping to the byte based extern character encoding (e.g. Latin1). So the question is what to do in that case? How do other systems deal with this problem? Michael
participants (1)
-
Michael Rueger