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

commits at source.squeak.org commits at source.squeak.org
Thu May 27 12:26:10 UTC 2021

Marcel Taeumel uploaded a new version of FFI-Kernel to project FFI:

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

Name: FFI-Kernel-mt.177
Author: mt
Time: 27 May 2021, 2:26:09.621609 pm
UUID: 4cb498da-9e06-9343-943b-bcb208915b9c
Ancestors: FFI-Kernel-mt.176

Adds #pointer alias to quickly get a pointer type.
Adds type lookup for various type representations such as string, symbol, or struct class.

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

Item was added:
+ ----- Method: ExternalType class>>lookupType: (in category 'instance lookup') -----
+ lookupType: structClassOrTypeNameOrType
+ 	"Answers a type from the given spec, which can be a name, a struct class, or an actual type. Approximate being a struct class via #isBehavior."
+ 	^ structClassOrTypeNameOrType isString
+ 		ifTrue: [self typeNamed: structClassOrTypeNameOrType]
+ 		ifFalse: [structClassOrTypeNameOrType isBehavior
+ 			ifTrue: [structClassOrTypeNameOrType externalType]
+ 			ifFalse: [structClassOrTypeNameOrType]]!

Item was added:
+ ----- Method: ExternalType class>>pointer (in category 'type constants - extra') -----
+ pointer
+ 	"Answers a generic pointer type, that is, void*"
+ 	^ ExternalType void asPointerType!

More information about the Squeak-dev mailing list