Overriding #class

Craig Latta craig at netjam.org
Thu Nov 15 18:39:11 UTC 2007


Hi Martin--

 > ...where in the compiler we can turn off this optimization? It is very
 > hard to debug the parser/compiler to find the correct place... :(

      Oh, I didn't change the compiler, I changed 
Interpreter>>bytecodePrimClass (see below) and rebuilt the interpreter.


      have fun,

-C

***

Interpreter>>bytecodePrimClass
      | receiver receiverClass |

      receiver := self internalStackTop.
      receiverClass := self fetchClassOf: receiver.
      (receiverClass = (self splObj: ClassProxy)) ifFalse: [
           self internalPop: 1 thenPush: receiverClass.
           ^self fetchNextBytecode].
      messageSelector := self specialSelector: 23.
      argumentCount := 0.
      self normalSend

--
Craig Latta
www.netjam.org





More information about the Squeak-dev mailing list