home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!gatech!bloom-beacon!eru.mt.luth.se!lunic!sunic!kth.se!news.kth.se!RICHARD
- From: RICHARD@CLYDE.ttt.kth.se
- Newsgroups: comp.lang.c++
- Subject: HELP: aggregate type question.
- Message-ID: <RICHARD.92Sep7210203@CLYDE.ttt.kth.se>
- Date: 7 Sep 92 20:02:03 GMT
- Sender: usenet@kth.se (Usenet)
- Organization: Department of TeleTransmission Theory
- Lines: 39
- Nntp-Posting-Host: clyde.ttt.kth.se
-
-
- I try to make a struct by inheriting from two other classes:
-
-
- struct Sequence {
- Sequence () {}
- };
-
- struct List : public Sequence {
- List () {}
- };
-
- struct Symbol {
- virtual int X();
- };
-
- struct Null : public Symbol, public List
- {
- virtual int X();
- };
-
- I compile with GCC 2.2.2, and it gives me the following error message:
-
- `List' fails to be an aggregate typedef.
-
- on the line which starts with "struct Null".
-
- First of all, I have no idea for now what an "aggregate typedef" is. Knowing
- would help a lot. No, I have not the ARM handy...
-
- So please, tell me what I am doing wrong here...
-
- --
- !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++!
- ! Richard Levitte, System manager ! tel: int+46-8-790 64 23 !
- ! Royal Institute of Technology ! fax: int+46-8-791 76 54 !
- ! Department of Teletransmition Theory ! Internet: richard@ttt.kth.se !
- ! S-100 44 Stockholm, Sweden ! !
- !---------------------------------------------------------------------------!
-