[Vm-dev] Re: Method executing but not sent to the receiver

Henrik Sperre Johansen henrik.s.johansen at veloxit.no
Tue Apr 26 10:50:25 UTC 2011


Say you have Class A:
inst vars : one two three

and method compiled on it:
foo
^one

Then you also have Class B:
inst vars: three two one

Then you do 
methodFoo := A >> #foo
methodFoo executeWithReceiver: B new one: 1; three: 3; yourself arguments:
#()

It'll return 3, which'll probably confuse those not very familiar with the
bytecodes.

Or using a class with no instvars, it'll crash in a similar manner to what
you get if you currently do:
Test methodDictionary at: #foo put: MCPackage >> #packageInfo.
Test >> #foo.
Test new foo






--
View this message in context: http://forum.world.st/Method-executing-but-not-sent-to-the-receiver-tp3417511p3475162.html
Sent from the Squeak VM mailing list archive at Nabble.com.


More information about the Vm-dev mailing list