In article <fa39fc69.0308191829.60aac4c3posting.google.com >,
[email]matthew.romainejp.sony.com[/email] (matt) wrote:
> Below is a snippet that I took from a simple tutorial on how to use
> CoreAudio; I've modified it a bit to serve my desired purpose, but I'm
> receiving a compile warning that I don't really understand. My goal
> is to be able to call an implementation's method.
> First, the code snippet:
>
> // define a C struct from the obj-C object so audio callback can
> access data
> typedef struct {
> defs(MyDoent);
> } mydoc_t;
>
[snip]
> [(*mydoc) propagateSampleBuffer]; <-- COMPILE WARNING ON THIS
> LINE
Don't put the * before mydoc. mydoc is a pointer to an ObjC object. When
you send messages to an object, you provide a pointer. The type 'id'
means "pointer to object".

You may still get a warning, since it's a pointer but the compiler
thinks it's a pointer to a struct. Just cast mydoc to id, or to
YourClassHere *, and you'll be fine.