[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-smalltalk] Fix for extend
From: |
Paolo Bonzini |
Subject: |
Re: [Help-smalltalk] Fix for extend |
Date: |
Sat, 25 Sep 2010 17:42:05 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.3 |
On 09/24/2010 10:58 PM, Mathieu Suen wrote:
Hi Paolo,
I have made a fix for the issue: http://smalltalk.gnu.org/project/issue/520.
You can take it from my repository.
I am not fan of the fix but at least it work.
No, it is more complicated than that. Here is a more complete testcase:
Eval [
(Object subclass: #AB)
instanceVariableNames: 'a'.
(Object subclass: #C)
instanceVariableNames: 'c';
createGetMethod: 'c';
createSetMethod: 'c'.
]
Eval [
cObj := C new.
cObj c: 34.
Smalltalk at: #TestObj put: cObj.
AB
instanceVariableNames: 'a b';
createGetMethod: 'b';
createSetMethod: 'b'.
^cObj c
]
Eval [
cObj := C new.
cObj c: 34.
^cObj instVarAt: 3
]
Eval [
TestObj b: 12.
AB instanceVariableNames: 'b'.
^TestObj b
]
Eval [
^TestObj instVarAt: 1
]
Eval [
^TestObj instVarAt: 2
]
Eval [
AB instanceVariableNames: 'b a'.
^TestObj b
]
Eval [
^TestObj instVarAt: 1
]
Eval [
^TestObj instVarAt: 3
]
Paolo