On Wednesday, 3 February 2016 at 20:30:01 UTC, Bambi wrote:
I'm pretty sure casting away a const pointer to a const value is undefined behaviour.

const data in C can be immutable, but also can be mutable and change over time, that's why immutable optimizations are illegal on it: you can't tell if it's immutable, the const qualifier tells nothing about that, it only helps the callee to not modify the data.

Reply via email to