Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1425.mcz
==================== Summary ====================
Name: System-mt.1425
Author: mt
Time: 28 September 2023, 10:22:20.27702 am
UUID: c446d3d6-39ea-e74f-84b2-dcf1487575eb
Ancestors: System-mt.1424
Complements Collections-mt.1051
=============== Diff against System-mt.1424 ===============
Item was changed:
----- Method: SmartRefStream>>next (in category 'read write') -----
next
+ "Really write three objects: (version, class structure, object). But only when called from the outside. NOTE THAT we do not have to #rehash anything here. See implementors of #comeFullyUpOnReload:. "
- "Really write three objects: (version, class structure, object). But only when called from the outside. "
| version ss object |
^ topCall == nil
ifTrue:
[topCall := #marked.
version := super next.
version class == SmallInteger ifFalse: [^ version].
"version number, else just a regular object, not in our format, "
self checkCrLf.
ss := super next.
ss class == Array ifFalse: [^ ss]. "just a regular object"
(ss at: 1) = 'class structure' ifFalse: [^ ss].
+ structures := ss at: 2.
- structures := (ss at: 2) rehash.
superclasses := (ss size > 3 and: [(ss at: 3) = 'superclasses'])
+ ifTrue: [ss at: 4] "class name -> superclass name"
- ifTrue: [(ss at: 4) rehash] "class name -> superclass name"
ifFalse: [Dictionary new].
(self verifyStructure = 'conversion method needed') ifTrue: [^ nil].
object := super next. "all the action here"
self restoreClassInstVars. "for UniClasses. version 4"
topCall := nil. "reset it"
object]
ifFalse:
[super next]
!
Marcel Taeumel uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-mt.1527.mcz
==================== Summary ====================
Name: Kernel-mt.1527
Author: mt
Time: 28 September 2023, 10:21:53.11702 am
UUID: d4fc65b6-ef98-b64b-af96-464763affa9d
Ancestors: Kernel-mt.1526
Complements Collections-mt.1051
=============== Diff against Kernel-mt.1526 ===============
Item was changed:
----- Method: Object>>readDataFrom:size: (in category 'objects from disk') -----
readDataFrom: aDataStream size: varsOnDisk
"Fill in the fields of self based on the contents of aDataStream. Return self.
Read in the instance-variables written by Object>>storeDataOn:.
NOTE: This method must send beginReference: before reading any objects from aDataStream that might reference it.
Allow aDataStream to have fewer inst vars. See SmartRefStream."
| cntInstVars cntIndexedVars |
cntInstVars := self class instSize.
self class isVariable
ifTrue: [cntIndexedVars := varsOnDisk - cntInstVars.
cntIndexedVars < 0 ifTrue: [
self error: 'Class has changed too much. Define a convertxxx method']]
ifFalse: [cntIndexedVars := 0.
cntInstVars := varsOnDisk]. "OK if fewer than now"
aDataStream beginReference: self.
1 to: cntInstVars do:
[:i | self instVarAt: i put: aDataStream next].
1 to: cntIndexedVars do:
[:i | self basicAt: i put: aDataStream next].
"Total number read MUST be equal to varsOnDisk!!"
- self rehash.
^ self "If we ever return something other than self, fix calls
on (super readDataFrom: aDataStream size: anInteger)"!
Marcel Taeumel uploaded a new version of Collections to project The Trunk:
http://source.squeak.org/trunk/Collections-mt.1051.mcz
==================== Summary ====================
Name: Collections-mt.1051
Author: mt
Time: 28 September 2023, 10:21:07.80602 am
UUID: a30c75a0-0736-404f-8a8d-88518a1de17c
Ancestors: Collections-mt.1050
Always #rehash hashed collections that come from disk. Note that #compact does not always work depending on the current size of the incoming objects.
Thanks to Jakob (jr) for the hint!
=============== Diff against Collections-mt.1050 ===============
Item was changed:
----- Method: HashedCollection>>comeFullyUpOnReload: (in category 'objects from disk') -----
comeFullyUpOnReload: smartRefStream
"Symbols have new hashes in this image."
+ self rehash.!
- self compact!
Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.1424.mcz
==================== Summary ====================
Name: System-mt.1424
Author: mt
Time: 27 September 2023, 1:39:22.934019 pm
UUID: d830c5c0-4931-a546-b8ee-fd493ca7b1d3
Ancestors: System-mt.1423
Complement Kernel-mt.1526
=============== Diff against System-mt.1423 ===============
Item was changed:
----- Method: SmartRefStream>>next (in category 'read write') -----
next
"Really write three objects: (version, class structure, object). But only when called from the outside. "
| version ss object |
^ topCall == nil
ifTrue:
[topCall := #marked.
version := super next.
version class == SmallInteger ifFalse: [^ version].
"version number, else just a regular object, not in our format, "
self checkCrLf.
ss := super next.
ss class == Array ifFalse: [^ ss]. "just a regular object"
(ss at: 1) = 'class structure' ifFalse: [^ ss].
structures := (ss at: 2) rehash.
superclasses := (ss size > 3 and: [(ss at: 3) = 'superclasses'])
ifTrue: [(ss at: 4) rehash] "class name -> superclass name"
ifFalse: [Dictionary new].
(self verifyStructure = 'conversion method needed') ifTrue: [^ nil].
+ object := super next. "all the action here"
- object := super next rehash. "all the action here"
self restoreClassInstVars. "for UniClasses. version 4"
topCall := nil. "reset it"
object]
ifFalse:
+ [super next]
- [super next rehash]
!
Marcel Taeumel uploaded a new version of Kernel to project The Trunk:
http://source.squeak.org/trunk/Kernel-mt.1526.mcz
==================== Summary ====================
Name: Kernel-mt.1526
Author: mt
Time: 27 September 2023, 1:38:59.304019 pm
UUID: 9bbe749b-d516-e146-8af2-4f5f7962faa0
Ancestors: Kernel-mt.1525
Fixes regression in DataStream from System-tpr.1411 to make SqueakMap catalog update again. Send #rehash only when the object is complete, not in the middle of a #next call that might be incomplete for cyclic dependencies.
=============== Diff against Kernel-mt.1525 ===============
Item was changed:
----- Method: Object>>readDataFrom:size: (in category 'objects from disk') -----
readDataFrom: aDataStream size: varsOnDisk
"Fill in the fields of self based on the contents of aDataStream. Return self.
Read in the instance-variables written by Object>>storeDataOn:.
NOTE: This method must send beginReference: before reading any objects from aDataStream that might reference it.
Allow aDataStream to have fewer inst vars. See SmartRefStream."
| cntInstVars cntIndexedVars |
cntInstVars := self class instSize.
self class isVariable
ifTrue: [cntIndexedVars := varsOnDisk - cntInstVars.
cntIndexedVars < 0 ifTrue: [
self error: 'Class has changed too much. Define a convertxxx method']]
ifFalse: [cntIndexedVars := 0.
cntInstVars := varsOnDisk]. "OK if fewer than now"
aDataStream beginReference: self.
1 to: cntInstVars do:
[:i | self instVarAt: i put: aDataStream next].
1 to: cntIndexedVars do:
[:i | self basicAt: i put: aDataStream next].
"Total number read MUST be equal to varsOnDisk!!"
+ self rehash.
^ self "If we ever return something other than self, fix calls
on (super readDataFrom: aDataStream size: anInteger)"!