
24 May
2010
24 May
'10
9:06 p.m.
On Mon, May 24, 2010 at 1:57 PM, Kumar Gala galak@kernel.crashing.org wrote:
What in the world does 'const' get me in C.
Actually, scrap that. A const function tells the compiler that, for a given set of parameters, the returned value is always the same, so the compiler will eliminate redundant calls to the function. But the problem is that it needs to be a const __attribute__, and the debug() call would need to be deleted for it to be valid anyway.
--
Timur Tabi
Linux kernel developer at Freescale