[squeak-dev] FFI: FFI-Kernel-mt.219.mcz

commits at source.squeak.org commits at source.squeak.org
Mon Aug 23 07:50:33 UTC 2021


Marcel Taeumel uploaded a new version of FFI-Kernel to project FFI:
http://source.squeak.org/FFI/FFI-Kernel-mt.219.mcz

==================== Summary ====================

Name: FFI-Kernel-mt.219
Author: mt
Time: 23 August 2021, 9:50:31.066089 am
UUID: 1b8fdd1b-0e40-9e4b-90ef-52be520fc1e9
Ancestors: FFI-Kernel-mt.218

Fixes init bug where atomic-type accessors (i.e., ExternalType class >> #int32_t) got lost after FFI-Kernel-mt.215.

=============== Diff against FFI-Kernel-mt.218 ===============

Item was added:
+ ----- Method: ExternalAtomicType class>>initializeAtomicTypeAccessors (in category 'class initialization') -----
+ initializeAtomicTypeAccessors
+ 	"Call this to (re-)initialize accessors for atomic types, even if there are no substantial changes to the types themselves."
+ 
+ 	self assert: [AtomicTypes notNil].
+ 	self assert: [AtomicTypes notEmpty].
+ 
+ 	self atomicTypesDo: [:type | type generateTypeAccessor].!

Item was changed:
  ----- Method: ExternalType class>>initializeAtomicTypes (in category 'class initialization') -----
  initializeAtomicTypes
  	"Private. (Re-)initialize all atomic types. Preserves object identity of all involved types. If the amount of types changed, use #resetAllAtomicTypes instead. Needs atomic-type codes to be initialized already."
  
  	self assert: [AtomicTypeCodes notNil].
  	self assert: [AtomicTypeCodes notEmpty].
  		
  	self basicInitializeAtomicTypes.
  	self invalidateAtomicTypes.
  	
  	ExternalAtomicType initializeAtomicTypes.
+ 	ExternalAtomicType initializeAtomicTypeCompanions.
+ 	ExternalAtomicType initializeAtomicTypeAccessors.
- 	ExternalAtomicType initializeAtomicTypeCompanions.	
  	
  	self initializeAtomicSends.!

Item was added:
+ ----- Method: ExternalType class>>initializeStructureTypeAccessors (in category 'class initialization') -----
+ initializeStructureTypeAccessors
+ 	"Call this to (re-)initialize accessors for types that have a referentClass, which generates/updates the class-side #externalType method according to the #useTypePool preference."
+ 
+ 	self allTypesDo: [:type |
+ 		type referentClass ifNotNil: [type generateTypeAccessor]].!

Item was changed:
  ----- Method: ExternalType class>>initializeStructureTypes (in category 'class initialization') -----
  initializeStructureTypes
  	"(Re-)initialize all structure types and all array types. Preserves object identity of all involved types. If the amount of types changed, use #resetAllStructureTypes instead."
  
  	self basicInitializeStructureTypes.
  	self invalidateStructureTypes.
  		
+ 	self initializeStructureTypeAccessors.
+ 	
  	"Trigger #noticeModificationOf: callback to actually initialize all structure types. Since we invalidated all types, we cannot use #defineAllChangedFields. We rely on the #noticeModificationOf: callback."
  	ExternalStructure defineAllFields.!

Item was changed:
  (PackageInfo named: 'FFI-Kernel') postscript: '"Update for array classes."
+ ExternalType initialize..'!
- ExternalType initialize.'!



More information about the Squeak-dev mailing list