[vorbis-dev] vorbisfile API ickiness

Rich Peters rpeters at micro-magic.com
Wed Nov 8 08:12:24 PST 2000



Hello all,

I have solved some of these issues in the past by doing this:

     struct OggVorbis_File

         // ... blah blah blah, more stuff
     } _File  ;

regards,
Rich

----- Original Message -----
From: "Monty" <xiphmont at xiph.org>
To: <vorbis-dev at xiph.org>
Sent: Wednesday, November 08, 2000 4:29 AM
Subject: Re: [vorbis-dev] vorbisfile API ickiness

>
> > The problem with this is that some anonymous struct type is
> > being created, and then aliased to OggVorbis_File... but
> > the fact that the base type is anonymous prevents me from
> > forward declaring OggVorbis_File like I want to (another
> > stupidity of C++).
>
> Really?  How evil.  I didn't know C++ was limited this way... are you
> sure (it should be a perfect superset of ANSI C, but I suspect I'm
> being naieve)
>
> > However, if it were defined like this, everything would work
> > great:
> >
> >     struct OggVorbis_File

> >         // ... blah blah blah, more stuff
> >     };
> >
> > Is there a problem with this?  It has been forever since
> > I programmed in C but I see in my ANSI version of the K&R book
> > that it is legal.  Is it not legal in K&R C or something?
>
> No, there is actually no reason not to do this.  (actually typedef
> struct OggVorbis_File{...)
>
> I'll make the change.
>
> Monty
>
> --- >8 ----
> List archives:  http://www.xiph.org/archives/
> Ogg project homepage: http://www.xiph.org/ogg/
> To unsubscribe from this list, send a message to
'vorbis-dev-request at xiph.org'
> containing only the word 'unsubscribe' in the body.  No subject is needed.
> Unsubscribe messages sent to the list will be ignored/filtered.
>

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the Vorbis-dev mailing list