Re: [OT] quick C struct void question

new topic     » goto parent     » topic index » view thread      » older message » newer message
petelomax said...

Just showing my ignorance. Obviously something like:

  typedef struct { 
                   void *p; 
  } P; 
is fine (it is, isn't it? getlost ).

Yes.

petelomax said...

I just quickly want to know what happens if you delete the *. It it illegal? Is it treated as a byte?

Pete

It's illegal.

 
pete.c:2: error: variable or field 'p' declared void 
 

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu