Fifo<>::Element is missing a virtual destructor

Stefan Thöni stefan.thoeni at gapfruit.com
Thu May 21 13:56:59 CEST 2020


Hi Genodians

I would like to create a hierarchy of classes on top of Fifo<>::Element
so these object can be stored in fifos:

class A : public Fifo<A>::Element
{
  virtual method() = 0;
};

class B : public A
{
  method() override { ... }
};

This won't compile because Fifo<>::Element is missing a virtual destructor.

Is there any reason for this? What do you think about adding the virtual
destructor to Fifo<>::Element?


Kind regards
Stefan

-- 
Freundliche Grüsse

Stefan Thöni
Chairman of the Board
Senior Security Architect
+41 79 610 64 95

gapfruit AG
Baarerstrasse 135
6300 Zug
https://gapfruit.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0x05D66A288F9939FF.asc
Type: application/pgp-keys
Size: 25417 bytes
Desc: not available
URL: <http://lists.genode.org/pipermail/users/attachments/20200521/eee1737f/attachment-0001.key>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: stefan_thoeni.vcf
Type: text/x-vcard
Size: 173 bytes
Desc: not available
URL: <http://lists.genode.org/pipermail/users/attachments/20200521/eee1737f/attachment-0001.vcf>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://lists.genode.org/pipermail/users/attachments/20200521/eee1737f/attachment-0001.sig>


More information about the users mailing list