`ref T` should be a type!!

Ali Çehreli acehreli at yahoo.com
Tue Apr 2 05:45:24 UTC 2019


On 04/01/2019 05:00 PM, Rubn wrote:
 > On Monday, 1 April 2019 at 20:51:44 UTC, Walter Bright wrote:
 >> On 4/1/2019 1:00 PM, Rubn wrote:
 >>> Arrays in C++ are just pointers.
 >>
 >> No, they're not.
 >
 > Yes they are.

Sensational but wrong. For example, there is no pointer in the following 
C++ code yet there is an array:

#include <iostream>

using namespace std;

struct S {
   int arr[10];
};

int main() {
   cout << sizeof(S) << '\n';
}

I know that you can qualify your statement to make it correct in some 
contexts but you are not doing so (yet?).

Ali



More information about the Digitalmars-d mailing list