fix discards const from pointer target