[Vm-dev] VM Maker: VMMaker.oscog-cb.1821.mcz

commits at source.squeak.org commits at source.squeak.org
Tue Apr 19 16:38:18 UTC 2016


ClementBera uploaded a new version of VMMaker to project VM Maker:
http://source.squeak.org/VMMaker/VMMaker.oscog-cb.1821.mcz

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

Name: VMMaker.oscog-cb.1821
Author: cb
Time: 19 April 2016, 9:36:36.685084 am
UUID: b05e8610-8a40-46c9-992a-99b19ce720ed
Ancestors: VMMaker.oscog-cb.1820

Got confused with the indexes. Sorry for the extra commit.

=============== Diff against VMMaker.oscog-cb.1820 ===============

Item was changed:
  ----- Method: InterpreterPrimitives>>primitiveGetImmutability (in category 'object access primitives') -----
  primitiveGetImmutability
  	<option: #IMMUTABILITY>
  	| rcvr |
+ 	rcvr := self stackValue: 0.
- 	rcvr := self stackValue: argumentCount.
  	self pop: argumentCount + 1 thenPushBool: (objectMemory isOopImmutable: rcvr)!

Item was changed:
  ----- Method: InterpreterPrimitives>>primitiveSetImmutability (in category 'object access primitives') -----
  primitiveSetImmutability
  	<option: #IMMUTABILITY>
  	| rcvr wasImmutable |
+ 	 rcvr := self stackValue: 1.
- 	 rcvr := self stackValue: argumentCount.
  	 (objectMemory isImmediate: rcvr) ifTrue:
  		[^self primitiveFailFor: PrimErrBadReceiver].
  	 wasImmutable := objectMemory isObjImmutable: rcvr.
  	 self stackTop = objectMemory trueObject
  		ifTrue:
  			[(self canBeImmutable: rcvr) ifFalse:
  				[^self primitiveFailFor: PrimErrInappropriate].
  			  objectMemory setIsImmutableOf: rcvr to: true]
  		ifFalse: [
  	self stackTop = objectMemory falseObject
  		ifTrue: [objectMemory setIsImmutableOf: rcvr to: false]
  	 	ifFalse:
  			[^self primitiveFailFor: PrimErrBadArgument]].
  	 self pop: argumentCount + 1 thenPushBool: wasImmutable!



More information about the Vm-dev mailing list