Re: Doubt in function typedef's

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 8, 2010 at 4:32 PM, Dexter <dexter@xxxxxxxxx> wrote:
They are exactly the same. Someone used () in one declaration but not the other, they are identical functionally.


On Tue, Jun 8, 2010 at 4:05 PM, Balachandar <bala1486@xxxxxxxxx> wrote:
Hello,
 I came across the following statements and confused about it.

typedef void vq_callback_t(struct virtqueue *);


and in some other file

vq_callback_t *callbacks[] = { skb_recv_done, skb_xmit_done, NULL};


Is this the same as
typedef void (*vq_callback_t)(struct virtqueue *);

vq_callback_t callbacks[] = { skb_recv_done, skb_xmit_done, NULL};


Thanks,
Bala


I apologize, my eyes completely missed the * on the second function. Disregard what I said previously ^^.

Dexter

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux