LWN.net Logo

The timer API: size or type safety?

The timer API: size or type safety?

Posted Dec 8, 2006 17:10 UTC (Fri) by liljencrantz (subscriber, #28458)
In reply to: The timer API: size or type safety? by viro
Parent article: The timer API: size or type safety?

That is so clever it hurts.

Am I correct in thinking that since check_callback_type never evaluates f or x, we also don't need to use typeof anymore, as we only truly reference f or x once? I.e. we can write this as:

check_callback_type( func, data );
timer->function = (void (*)(void *)) func;
timer->data = (void *) data;


(Log in to post comments)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds