Mantis Bugtracker
  

Viewing Issue Advanced Details Jump to Notes ] View Simple ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0007229 [Squeak] VM tweak always 11-19-08 23:27 01-09-11 23:01
Reporter mikevdg View Status public  
Assigned To lewis
Priority normal Resolution open Platform
Status assigned   OS
Projection none   OS Version
ETA none Fixed in Version Product Version 3.10.2
  Product Build
Summary 0007229: Remove optimisation for >>class
Description The VM uses bytecode 199 to send >>class; the implementation is optimised to not do a message send but to return the class directly.

In some cases such as using message catchers (i.e. the trick where you override >>doesNotUnderstand on a ProtoObject subclass), this is undesired behaviour. The optimisation prevents the user from being able to override the behaviour of >>class.

(code below from Eliot Miranda)

To fix this change
bytecodePrimClass
| rcvr |
rcvr := self internalStackTop.
self internalPop: 1 thenPush: (self fetchClassOf: rcvr).
self fetchNextBytecode.
to
bytecodePrimClass
messageSelector := self specialSelector: 23.
argumentCount := 0.
self normalSend.
Steps To Reproduce
Additional Information
Attached Files

- Relationships

There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
11-19-08 23:27 mikevdg New Issue
11-19-08 23:27 mikevdg Status new => assigned
11-19-08 23:27 mikevdg Assigned To  => tim
11-20-08 11:55 lewis Issue Monitored: lewis
01-09-11 23:01 lewis Assigned To tim => lewis


Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
34 total queries executed.
28 unique queries executed.
Powered by Mantis Bugtracker