On 05/12/2020 18:29, Andrea Corallo via Gcc-help wrote: > David Brown <david.brown@xxxxxxxxxxxx> writes: > > [...] > >> There is no way in C to say that there can't be anything else that >> changes the object. > > I think it would be nice to have, if not in C at least in GCC. > > Andrea > Agreed. But I think there are so many possible things about constness that it would be nice to have, that it could quickly get out of hand. I'd really like a way to tell the compiler that a given object gets set once during some early function in the program, and can never change after that. But I can't think of any good syntax for that.