Re: [patch] x86, ptrace: void dopiness

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: linux-os (Dick Johnson)
Date: Friday, September 19, 2008 - 6:17 am

On Fri, 19 Sep 2008, Markus Metzger wrote:


I don't agree. Casting the return value to void, since it
takes extra steps on the part of the writer, means that the
writer is deliberately ignoring the return value because
it has no objective use in the code.

Just letting unused return-values be ignored means that
the writer either wanted to ignore it or simply forgot
about it. The cast is supposed to remove doubt. Certain
user-mode functions that are obviously used for effect
like printf(), are exempt.

That said, putting a space between the cast and the
function name helps in the use of some text-scanning
tools and therefore improves maintainability.


Cheers,
Dick Johnson
Penguin : Linux version 2.6.25.17 on an i686 machine (4786.70 BogoMips).
My book : http://www.AbominableFirebug.com/
_


****************************************************************
The information transmitted in this message is confidential and may be privileged. Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited. If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to DeliveryErrors@analogic.com - and destroy all copies of this information, including any attachments, without reading or disclosing them.

Thank you.
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch] x86, ptrace: void dopiness, Markus Metzger, (Fri Sep 19, 5:52 am)
Re: [patch] x86, ptrace: void dopiness, linux-os (Dick Johnson), (Fri Sep 19, 6:17 am)
Re: [patch] x86, ptrace: void dopiness, Ingo Molnar, (Mon Sep 22, 4:50 am)
RE: [patch] x86, ptrace: void dopiness, Metzger, Markus T, (Mon Sep 22, 5:00 am)
Re: [patch] x86, ptrace: void dopiness, Ingo Molnar, (Mon Sep 22, 5:07 am)
RE: [patch] x86, ptrace: void dopiness, Metzger, Markus T, (Tue Sep 23, 4:30 am)
Re: [patch] x86, ptrace: void dopiness, Ingo Molnar, (Tue Sep 23, 4:48 am)