Lies in education [was Re: The "loop and a half"]

Gregory Ewing greg.ewing at canterbury.ac.nz
Fri Oct 13 00:37:40 EDT 2017


bartc wrote:
> (2) Declare data to be put into read-only memory as you say. That's fine 
> with a 'const int * p', but what about a 'int * const p'?

If the compiler can tell where p is initially pointing, it could
put the pointer in read-only memory. Probably unlikely to happen
in real code, though.

-- 
Greg



More information about the Python-list mailing list