'From Squeak4.5 of 17 November 2015 [latest update: #15479] on 17 November 2015 at 4:25:11 pm'!!Context methodsFor: 'mirror primitives' stamp: 'eem 5/13/2009 14:21'!object: anObject basicAt: index 	"Answer the value of an indexable element in the argument anObject without sending	 it a message. Fail if the argument index is not an Integer or is out of bounds, or if	 anObject is not indexable. This mimics the action of the VM when it indexes an object.	 Used to simulate the execution machinery by, for example, the debugger.	 Primitive.  See Object documentation whatIsAPrimitive."	<primitive: 60>	index isInteger ifTrue: [self errorSubscriptBounds: index].	index isNumber		ifTrue: [^self object: anObject basicAt: index asInteger]		ifFalse: [self errorNonIntegerIndex]! !!Context methodsFor: 'mirror primitives' stamp: 'eem 5/13/2009 14:21'!object: anObject basicAt: index put: value 	"Store the last argument 	 value in the indexable element of the argument anObject indicated by index without sending	 anObject a message. Fail if the argument index is not an Integer or is out of bounds, or if	 anObject is not indexable, or if value is an inappropriate value for anObject's indexable slots.	 This mimics the action of the VM when it indexes an object.	 Used to simulate the execution machinery by, for example, the debugger.	 Primitive.  See Object documentation whatIsAPrimitive."	<primitive: 61>	index isInteger		ifTrue: [(index >= 1 and: [index <= (self objectSize: anObject)])					ifTrue: [self errorImproperStore]					ifFalse: [self errorSubscriptBounds: index]].	index isNumber		ifTrue: [^self object: anObject basicAt: index asInteger put: value]		ifFalse: [self errorNonIntegerIndex]! !!Context methodsFor: 'mirror primitives' stamp: 'eem 5/13/2009 14:23'!object: anObject eqeq: anOtherObject 	"Answer whether the first and second arguments are the same object (have the	 same object pointer) without sending a message to the first argument.  This	 mimics the action of the VM when it compares two object pointers.  Used to	 simulate the execution machinery by, for example, the debugger.	 Primitive.  See Object documentation whatIsAPrimitive."	<primitive: 110>	self primitiveFailed! !!Context methodsFor: 'mirror primitives' stamp: 'eem 4/8/2009 19:27'!object: anObject instVarAt: anIndex	"Primitive. Answer a fixed variable in an object. The numbering of the 	 variables corresponds to the named instance variables. Fail if the index 	 is not an Integer or is not the index of a fixed variable. Essential for the	 debugger. See  Object documentation whatIsAPrimitive."	<primitive: 73>	"Access beyond fixed variables."	^self object: anObject basicAt: anIndex - (self objectClass: anObject) instSize! !!Context methodsFor: 'mirror primitives' stamp: 'eem 4/8/2009 19:30'!object: anObject instVarAt: anIndex put: aValue 	"Primitive. Store a value into a fixed variable in the argument anObject.	 The numbering of the variables corresponds to the named instance	 variables.  Fail if the index is not an Integer or is not the index of a	 fixed variable.  Answer the value stored as the result. Using this	 message violates the  principle that each object has sovereign control	 over the storing of values into its instance variables. Essential for the	 debugger. See Object documentation whatIsAPrimitive."	<primitive: 74>	"Access beyond fixed fields"	^self object: anObject basicAt: anIndex - (self objectClass: anObject) instSize put: aValue! !!Context methodsFor: 'mirror primitives' stamp: 'dtl 12/11/2011 19:39'!object: anObject perform: selector withArguments: argArray inClass: lookupClass	"Send the selector, aSymbol, to anObject with arguments in argArray.	 Fail if the number of arguments expected by the selector 	 does not match the size of argArray, or if lookupClass	 cannot be found among the anObject's superclasses.	 Primitive. Essential for the debugger."	<primitive: 100 error: error>	(selector isSymbol) ifFalse:		[^self error: 'selector argument must be a Symbol'].	(argArray isMemberOf: Array) ifFalse:		[^self error: 'argArray must be an Array'].	(selector numArgs = argArray size)		ifFalse: [^self error: 'incorrect number of arguments'].	((self objectClass: anObject) == lookupClass	 or: [(self objectClass: anObject) inheritsFrom: lookupClass]) ifFalse:		[^self error: 'lookupClass is not in anObject''s inheritance chain'].	self primitiveFailed! !!Context methodsFor: 'mirror primitives' stamp: 'eem 5/13/2009 14:21'!objectClass: anObject	"Answer the class of the argument anObject without sending it a message.	 This mimics the action of the VM when it fetches an object's class.  Used to	 simulate the execution machinery by, for example, the debugger.	 Primitive.  See Object documentation whatIsAPrimitive."	<primitive: 111>	self primitiveFailed! !!Context methodsFor: 'mirror primitives' stamp: 'eem 5/13/2009 14:21'!objectSize: anObject	"Answer the number of indexable variables in the argument anObject without sending	 it a message. This mimics the action of the VM when it fetches an object's variable size.	 Used to simulate the execution machinery by, for example, the debugger.	 Primitive.  See Object documentation whatIsAPrimitive."	<primitive: 62>	"The number of indexable fields of fixed-length objects is 0"	^0! !