The Inbox: Kernel-HenrikSperreJohansen.522.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

The Inbox: Kernel-HenrikSperreJohansen.522.mcz

commits-2
A new version of Kernel was added to project The Inbox:
http://source.squeak.org/inbox/Kernel-HenrikSperreJohansen.522.mcz

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

Name: Kernel-HenrikSperreJohansen.522
Author: HenrikSperreJohansen
Time: 10 December 2010, 11:35:02.564 am
UUID: 52384bb5-4b18-9e49-8292-cf8bb55e06aa
Ancestors: Kernel-ul.521

adoptInstance: , an alternative interface to primitiveChangeClassTo:.

Uses primitive if available, if not the equivalent primitiveChangeClassTo: expression (only in Cog for now)

=============== Diff against Kernel-ul.521 ===============

Item was added:
+ ----- Method: Behavior>>adoptInstance: (in category 'instance creation') -----
+ adoptInstance: anInstance
+ "Change the class of anInstance to me.
+ Primitive (only found in Cog) should follow the same rules as described in primitiveChangeClassTo:"
+
+ <primitive: 160 error: ec>
+ ^anInstance primitiveChangeClassTo: self basicNew.!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Kernel-HenrikSperreJohansen.522.mcz

David T. Lewis
I added Eliot's #primitiveAdoptInstance to VMMaker for the
interpreter VM, so this should be present in future VM builds
for the traditional interpreter as well as for Cog.

Dave

On Fri, Dec 10, 2010 at 10:35:08AM +0000, [hidden email] wrote:

> A new version of Kernel was added to project The Inbox:
> http://source.squeak.org/inbox/Kernel-HenrikSperreJohansen.522.mcz
>
> ==================== Summary ====================
>
> Name: Kernel-HenrikSperreJohansen.522
> Author: HenrikSperreJohansen
> Time: 10 December 2010, 11:35:02.564 am
> UUID: 52384bb5-4b18-9e49-8292-cf8bb55e06aa
> Ancestors: Kernel-ul.521
>
> adoptInstance: , an alternative interface to primitiveChangeClassTo:.
>
> Uses primitive if available, if not the equivalent primitiveChangeClassTo: expression (only in Cog for now)
>
> =============== Diff against Kernel-ul.521 ===============
>
> Item was added:
> + ----- Method: Behavior>>adoptInstance: (in category 'instance creation') -----
> + adoptInstance: anInstance
> + "Change the class of anInstance to me.
> + Primitive (only found in Cog) should follow the same rules as described in primitiveChangeClassTo:"
> +
> + <primitive: 160 error: ec>
> + ^anInstance primitiveChangeClassTo: self basicNew.!
>