const

suggest change

A type specifier; when applied to a type, produces the const-qualified version of the type. See const keyword for details on the meaning of const.

const int x = 123;
x = 456;    // error
int& r = x; // error

struct S {
    void f();
    void g() const;
};
const S s;
s.f(); // error
s.g(); // OK

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents