Fred Chou <[email protected]> wrote:
>Hi,
>
>On Mon, Dec 23, 2013 at 8:03 PM, Bernd Petrovitsch <
>[email protected]> wrote:
>[...]
>> And the macro just avoids to copy-paste identical lines/logic.
>
>Thank you all for the explanation. Originally I was wondering if there
>could be some other reasons. So the main (or only?) purpose of the
>macro is
>to save some typing, and in terms of functionality I could equivalently
>call each handlers.
>
>Fred
If you do decide to inline the code, you should probably get rid of the do
while(0) part.
That exists just to get rid of side effects of using macros in various syntax
situations.
http://c-faq.com/cpp/multistmt.html
Greg
--
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
_______________________________________________
Kernelnewbies mailing list
[email protected]
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies