Avoid "cast discards const qualifier from pointer target type" from GCC.