b3hn4m
b3hn4m

Reputation: 75

The interpretation of double const* const* X in c++

Given that X is a array of arrays, what is the interpretation of

double const* const* X 

in c++? Is it correct to say that X is a pointer to a constant pointer to a constant double?

Upvotes: 0

Views: 259

Answers (1)

Fantastic Mr Fox
Fantastic Mr Fox

Reputation: 33864

Yes.

From cdecl:

declare X as pointer to const pointer to const double

cdecl is an awesome tool for those the types of people who like to use calculators instead of doing mental maths (aka engineers, because we are lazy).

Upvotes: 3

Related Questions