Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!wuarchive!cs.utexas.edu!tut.cis.ohio-state.edu!att!dptg!ulysses!andante!alice!ark From: ark@alice.UUCP (Andrew Koenig) Newsgroups: comp.lang.c Subject: Re: self contained pointers to structures Keywords: strange interaction Message-ID: <10181@alice.UUCP> Date: 27 Nov 89 14:14:05 GMT References: <10350@attctc.Dallas.TX.US> Distribution: na Organization: AT&T Bell Laboratories, Liberty Corner NJ Lines: 20 In article <10350@attctc.Dallas.TX.US>, bobc@attctc.Dallas.TX.US (Bob Calbridge) writes: > I tried to implement it like this: > struct event { > int timing: > int count; > struct event *next; > }; > Of course, the compiler complains because the definition of the structure is > incomplete at that point. If your compiler rejects this, it's badly broken. There's nothing wrong with declaring a pointer to an (as yet) unknown structure. -- --Andrew Koenig ark@europa.att.com