[BUG][Q] Form saving and reloading

Yisrael Lowenstein gte356h at prism.gatech.edu
Wed Apr 24 15:45:53 UTC 2002


Form fromBinaryStream:
has this test in it when loading saved forms:

	firstByte = 2 ifTrue: [
		"new Squeak form format"
		^ self new readFrom: aBinaryStream].

The problem is that form writeOn: doesn't put a 2 as the first byte --
therefore, you can not read in a Form that you wrote out!

This is easy enough to fix (just "binaryStream nextPut: 2" before you
"writeOn: binaryStream")...but I was thinking there was probably a reason
this was being done this way...anyone know?

	Lushi

 o      |Yisrael Lowenstein: Computer Science Master's Student & Squeaker
   ()  o|lushi at bigfoot.com; gte356h at prism.gatech.edu; lushi at cc.gatech.edu
o_/||\/ |"Before you criticize a man, walk a mile in his shoes. That way
   ||   | when you do criticize him, you'll be a mile away and have his
  _/\_  | shoes." - Unknown                    AIM: YisraelL  ICQ: 1037061
  Class Schedule: http://www.prism.gatech.edu/~gte356h/schedule/





More information about the Squeak-dev mailing list