This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
How to create C++ built-in type
- From: Klesk <kleskmail at gmail dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Sat, 15 Aug 2009 19:57:55 +0200
- Subject: 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