[Newbies] Send super to trait?

Thiede, Christoph Christoph.Thiede at student.hpi.uni-potsdam.de
Fri May 7 16:13:15 UTC 2021


Hi all,


I just was trying to activate a super method from a trait but got a DNU:


MyTrait >> #foo ^0

Object subclass: MyObject uses: MyTrait.

MyObject >> #foo ^super foo + 1


Is this not how traits are expected to work? Or is there any other way to reuse the default logic specified in the trait? Do I need to return to traditional inheritance in order to achieve this?


Thanks in advance!


Best,

Christoph

<http://www.hpi.de/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/beginners/attachments/20210507/b16ba214/attachment-0001.html>


More information about the Beginners mailing list