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

commits at source.squeak.org commits at source.squeak.org
Thu Jan 3 21:51:16 UTC 2013


Eliot Miranda uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-eem.248.mcz

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

Name: VMMaker.oscog-eem.248
Author: eem
Time: 3 January 2013, 1:48:51.874 pm
UUID: 325b96ad-3c25-438e-af36-04a93839f195
Ancestors: VMMaker.oscog-eem.247

Fix snafu in revised build info generation.

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

Item was changed:
  ----- Method: CCodeGenerator>>fileHeaderVersionStampForSourceClass: (in category 'C code generator') -----
  fileHeaderVersionStampForSourceClass: sourceClass
  	"Answer a suitable version stamp to include in the header."
  	| exportBuildInfo slangDescription sourceDescription |
  	[exportBuildInfo := sourceClass isInterpreterClass
  						ifTrue: ['char *__interpBuildInfo = __buildInfo;']
  						ifFalse:
  							[sourceClass isCogitClass
  								ifTrue: ['char *__cogitBuildInfo = __buildInfo;']
  								ifFalse:
  									[sourceClass isPluginClass ifTrue:
  										[sourceClass exportBuildInfoOrNil]]]]
  		on: MessageNotUnderstood
  		do: [:ex| ex resume: false].
  	[slangDescription := self class monticelloDescriptionFor: self class.
  	 sourceClass ifNotNil:
  		[sourceDescription := [sourceClass monticelloDescription]
  								on: MessageNotUnderstood
  								do: [:ex| self class monticelloDescriptionFor: sourceClass]]]
  		on: Error
  		do: [:ex| | now |
  			now := Time dateAndTimeNow printString.
  			^String streamContents:
  				[:s|
  				s nextPutAll: '/* Automatically generated from Squeak on '.
  				s nextPutAll: now.
  				s nextPutAll: ' */'; cr; cr.
  				s nextPutAll: 'static char __buildInfo[] = "Generated on '.
  				s nextPutAll: now.
  				s nextPutAll: '. Compiled on "'.
  				s nextPutAll: '__DATE__ ;'; cr.
  				exportBuildInfo ifNotNil:
  					[s nextPutAll: exportBuildInfo; cr].
  				s cr]].
  	^String streamContents:
  		[:s|
  		s nextPutAll: '/* Automatically generated by\	' withCRs.
+ 		s nextPutAll: slangDescription.
- 		s nextPutAll: (slangDescription copyReplaceAll: '\' withCRs with: '\	' withCRs)..
  		sourceDescription ifNotNil:
+ 			[s nextPutAll: '\   from\	' withCRs; nextPutAll: (sourceDescription copyReplaceAll: '\' withCRs with: '\	' withCRs)].
- 			[s nextPutAll: '\   from\	' withCRs; nextPutAll: sourceDescription].
  		s cr; nextPutAll: ' */'; cr.
  		sourceDescription ifNotNil:
  			[s nextPutAll: 'static char __buildInfo[] = "'.
+ 			 s nextPutAll: (sourceDescription copyReplaceAll: '\' withCRs with: '\n\', '\' withCRs).
- 			 s nextPutAll: sourceDescription.
  			 s nextPutAll: ' " __DATE__ ;'; cr.
  			exportBuildInfo ifNotNil:
  				[s nextPutAll: exportBuildInfo; cr].
  			s cr]]!



More information about the Vm-dev mailing list