Why it is impossible to create an array of references in c++? -


C ++ Standards 8.3.2 / 4 says:

Any reference to the references There will be no array of references, and no signal for reference.

But I do not understand why this restriction has been added to C ++. Code bellow in my opinion can be easily compiled and worked? What is the real reason for this restriction?

  int a = 10, b = 20; Int and c [] = {a, b};  

Because indexing is actually an underlying conversion form for an indicator , Then the indicative arithmetic, to support it, you also have to support pointers for references, and to determine what the meaning of arithmetic is on them.

Comments