super super

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

super super

HilaireFernandes
Hi,

Is there a way from an instance to access a method situated 2 layers up
in the class hierarchy?

A kind of super super.

Thanks

Hilaire
--
Dr. Geo
http://drgeo.eu


Reply | Threaded
Open this post in threaded view
|

Re: super super

Brad Selfridge
You should be able to call super super, as high up as you need to go. At least you can in VA Smalltalk.

Brad Selfridge
913-269-2385

> On Jan 15, 2017, at 3:42 PM, Hilaire <[hidden email]> wrote:
>
> Hi,
>
> Is there a way from an instance to access a method situated 2 layers up
> in the class hierarchy?
>
> A kind of super super.
>
> Thanks
>
> Hilaire
> --
> Dr. Geo
> http://drgeo.eu
>
>

Brad Selfridge
Reply | Threaded
Open this post in threaded view
|

Re: super super

Henrik-Nergaard
In reply to this post by HilaireFernandes
#perform:withArugments:inSuperclass:

| menu |

menu := MenuMorph new.
menu isMorph. "true"
menu perform: #isMorph withArguments: #() inSuperclass: Morph. "true"
menu perform: #isMorph withArguments: #() inSuperclass: Object."false"
menu perform: #isMorph withArguments: #() inSuperclass: ProtoObject. "Error #isMorph not implemented"

Best regards,
Henrik

-----Opprinnelig melding-----
Fra: Pharo-users [mailto:[hidden email]] På vegne av Hilaire
Sendt: 15 January 2017 21:42
Til: [hidden email]
Emne: [Pharo-users] super super

Hi,

Is there a way from an instance to access a method situated 2 layers up in the class hierarchy?

A kind of super super.

Thanks

Hilaire
--
Dr. Geo
http://drgeo.eu


Reply | Threaded
Open this post in threaded view
|

Re: super super

HilaireFernandes
Thanks Henrik

Le 15/01/2017 à 22:33, Henrik Nergaard a écrit :
> menu perform: #isMorph withArguments: #() inSuperclass: ProtoObject. "Error #isMorph not implemented"

--
Dr. Geo
http://drgeo.eu