[Vm-dev] VM Maker: VMMaker.oscog-eem.2527.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Mar 6 19:22:01 UTC 2019

Eliot Miranda uploaded a new version of VMMaker to project VM Maker:

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

Name: VMMaker.oscog-eem.2527
Author: eem
Time: 6 March 2019, 11:21:46.164876 am
UUID: 6941605a-42c2-4ac0-82dd-7945ac547937
Ancestors: VMMaker.oscog-eem.2526

Ho hum.  That default intialization for plgin source generation requires a little more effort.

=============== Diff against VMMaker.oscog-eem.2526 ===============

Item was added:
+ ----- Method: VMClass class>>initializeForPlugins: (in category 'initialization') -----
+ initializeForPlugins: optionsDictionaryOrArray
+ 	"Do a default initialization, suitable for generating plugin sources."
+ 	StackInterpreterSimulator
+ 		initializeWithOptions: optionsDictionaryOrArray
+ 		objectMemoryClass: ObjectMemory!

Item was changed:
  ----- Method: VMMaker class>>makerFor:and:with:to:platformDir: (in category 'instance creation') -----
  makerFor: interpreterClass and: cogitClassOrNil with: optionsPairsArrayArg to: srcDirName platformDir: platDirName
  	"Initialize a VMMaker to generate the VM to the given target directory."
  	| optionsPairsArray |
  	optionsPairsArray := (cogitClassOrNil isNil or: [optionsPairsArrayArg includes: #Cogit])
  							ifTrue: [optionsPairsArrayArg]
  							ifFalse: [optionsPairsArrayArg, { #Cogit. cogitClassOrNil name }].
+ 	VMClass initializeForPlugins: optionsPairsArray.
- 	VMClass initializeWithOptions: optionsPairsArray.
  	^(self forPlatform: 'Cross')
  		sourceDirectoryName: (self fullNameForPath: srcDirName);
  		platformRootDirectoryName: (self fullNameForPath: platDirName);
  		options: optionsPairsArray;
  		interpreterClass: interpreterClass;

Item was changed:
  ----- Method: VMMaker>>generateExternalPlugin: (in category 'generate sources') -----
  generateExternalPlugin: pluginName 
  	"generate the named external plugin"
  	| exports plugin |
  	"Refuse to translate this plugin if it requires platform specific files and they are not present."
  	[plugin := self validateExternalPlugin: pluginName]
  		on: VMMakerException
  		do: [:ex|
  			logger show: 'external plugin ' , plugin name , ' failed to validate: ' , ex messageText; cr.
+ 	VMClass initializeForPlugins: #().
- 	VMClass initializeWithOptions: #().
  	[exports := plugin
  					translateInDirectory: (self externalPluginsDirectoryFor: plugin)
  					doInlining: inline]
  		on:  ProvideAnswerNotification
  		do: [:ex|
  			ex tag == #logger
  				ifTrue: [ex resume: logger]
  				ifFalse: [ex pass]].
  	exports ifNotNil: "if exp is nil we skip this since the plugin was already up to date"
  		[logger show: 'external plugin ' , plugin name , ' generated as ' , plugin moduleName; cr.
  		 self export: exports forExternalPlugin: plugin.
  		 self processFilesForExternalPlugin: plugin]!

More information about the Vm-dev mailing list