Read Only issue

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

Read Only issue

MrGwen
Hi Paolo,

There is an issue in ProcessBeingTerminated class>>#initialize.
It tries to change a RO compiled method:

diff --git a/kernel/SysExcept.st b/kernel/SysExcept.st
index afd923d..9660f7c 100644
--- a/kernel/SysExcept.st
+++ b/kernel/SysExcept.st
@@ -251,6 +251,7 @@ Notification subclass: ProcessBeingTerminated [

      ProcessBeingTerminated class >> initialize [
         (UndefinedObject>>#'__terminate')
+           makeReadOnly: false;
             descriptor: ((MethodInfo new: 1)
                 methodClass: UndefinedObject;
                 selector: #'__terminate';
@@ -268,7 +269,8 @@ Notification subclass: ProcessBeingTerminated [
                                     #found ]
                                 ifFalse: [nil] ].
                         [ :context | ] });
-               yourself)
+               yourself);
+           makeReadOnly: true
      ]

      description [

Gwen

_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk
Reply | Threaded
Open this post in threaded view
|

Re: Read Only issue

Paolo Bonzini-2
Thanks, I suppose that you saw this while playing with making instance
variables read-only as well?

Paolo

_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk
Reply | Threaded
Open this post in threaded view
|

Re: Read Only issue

MrGwen
On 05/19/2011 02:18 PM, Paolo Bonzini wrote:
> Thanks, I suppose that you saw this while playing with making instance
> variables read-only as well?
>
> Paolo

Yes

Gwen

_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk