Re: [IDEA+RFC] Possible solution for min()/max() war

From: Linus Torvalds (torvalds@transmeta.com)
Date: Tue Aug 28 2001 - 20:13:19 EST


On Wed, 29 Aug 2001, Daniel Phillips wrote:
>
> min(host->scsi.SCp.this_residual, (unsigned) DMAC_BUFFER_SIZE / 2);

Sure.

If you put the type information explicitly, you can get it right.

Which is, btw, _exactly_ why the min() function takes the type explicitly.

                Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Aug 31 2001 - 21:00:32 EST