Is there anyway to determine if a pointer-to-const points to a const object?
bool is_const_object(const int* p) {
return ???;
}
int main() {
int x = 42;
const int y = 43;
assert(!is_const_object(&x));
assert(is_const_object(&y));
}