This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to create C++ built-in type


Hi

C++ has many built-in types (int, float etc.), how to create a new
built-in type for example - how to make 'Test' defined as struct:
'Test { int a,b; };' built-in type, so that for example this code
would be correct:

int main()
{
   int x = 100;
   Test z;  // it's not defined, but it's built-in type so it should be OK
   z.a = x;
   return 0;
}

-- 
Klesk


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]