Mega Code Archive

 
Categories / Visual C++ .NET / Structure
 

Struct with copy constructor

#include "stdafx.h" using namespace System; ref struct R {    R()    {       val = 1;    }      R( R% r)    {       val = r.val;    }    property int val; }; int main() {     R r; }