Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

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

Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo
Status: FailingTest
Owner: [hidden email]
Labels: Type-Bug Milestone-2.0

New issue 6680 by [hidden email]: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

testInstanceSideMethodsWithNilKeyInLastLiteral


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo
Updates:
        Cc: [hidden email]

Comment #1 on issue 6680 by marianopeck: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

Issue 6644 has been merged into this issue.


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo

Comment #2 on issue 6680 by marianopeck: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

BTw...I tried to ask  in the mailng list some time ago...noone answer, and  
I couldn't find which was the problem...
http://forum.world.st/nil-key-in-last-literal-in-instance-side-methods-reproducible-td4646398.html


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo

Comment #3 on issue 6680 by [hidden email]: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

More information: it seems to happen only when a class is changing shape  
and then for *all* methods.
This means, something is going wrong when migrating methods to  
shape-changed classes.

look at #binding of Class:


binding
        "Answer a binding for the receiver, sharing if possible"
       | binding |
        binding := self environment associationAt: name ifAbsent: [nil -> self].
        ^binding value == self ifTrue: [binding] ifFalse: [nil -> self]


When a class is renamed, then it will return nil->self as the binding.

If this is changed to

binding
        "Answer a binding for the receiver, sharing if possible"
    ^ self environment associationAt: name ifAbsent: [ nil -> self ]

The bug disappears... but I am not happy with that, as it is not the real  
binding
of a class that has the same name yet is not in the environment.

So next step: check what is done when class shape is changed.







_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo
Updates:
        Status: FixToInclude

Comment #4 on issue 6680 by [hidden email]: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

so, yes, we should just change #binging. Binding has the meaning "give me  
the association in Smalltalk globals with your name".



Attachments:
        Class-binding.st  314 bytes


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo
Updates:
        Status: Integrated

Comment #5 on issue 6680 by [hidden email]: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

in 2.0 294


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo

Comment #6 on issue 6680 by marianopeck: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

Great catch Marcus. I did some research. Previously, we had that same  
version you have just commited. Then, we change it as part of this issue:  
http://code.google.com/p/pharo/issues/detail?id=1921
now I wonder what happens regarding that....


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo

Comment #7 on issue 6680 by marianopeck: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

it says "Fix handling of Class>>binding:
- Verify that the registered class in the environment is the receiver"


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker
Reply | Threaded
Open this post in threaded view
|

Re: Issue 6680 in pharo: Failing test: testInstanceSideMethodsWithNilKeyInLastLiteral

pharo

Comment #8 on issue 6680 by [hidden email]: Failing test:  
testInstanceSideMethodsWithNilKeyInLastLiteral
http://code.google.com/p/pharo/issues/detail?id=6680

yes, but it will always return the wrong binding... the binding is fixed in  
classbuilder due to the becomeForward: much later.


_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-bugtracker