型 
基本型 
予約語 | 説明 | サイズ(byte) | 初期値 | void | 型なし | - | - | bool | ブール値 | 実行環境で変わる | false | byte ubyte uint8 u8 | 符号無し8bit整数 | 1 | 0 | sbyte sint8 s8 | 符号有り8bit整数 | 1 | 0 | short sshort sint16 s16 | 符号有り16bit整数 | 2 | 0 | ushort uint16 u16 | 符号無し16bit整数 | 2 | 0 | int sint sint32 s32 | 符号有り32bit整数 | 4 | 0 | uint uint32 u32 | 符号無し32bit整数 | 4 | 0 | long slong sint64 s64 | 符号有り64bit整数 | 8 | 0 | ulong uint64 u64 | 符号無し64bit整数 | 8 | 0 | float float32 f32 | 32bit浮動小数点数 | 4 | 0 | double float64 f64 | 64bit浮動小数点数 | 8 | 0 | char | 8bit文字列(UTF-8) | 1 | 0x00 | wchar | 16bit文字列(UTF-16) | 2 | 0x0000 | dchar | 32bit文字列(UTF-32) | 4 | 0x000000000 | object handle | ガベージコレクト対象のオブジェクトの参照 | 4 | null | pointer | 非ガベージコレクト対象のデータのポインタ | 実行環境で変わる | null |
構造データ型 
ユーザー定義型 
- class
- enum
- interface
- struct
- pod
- utility
object handle 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
-
|
-
|
|
!
|
|
-
|
|
|
|
|
|
-
!
|
|
!
|
!
| class Sample
{
class Pos
{
int x;
int y;
};
static void Example()
{
Pos@ pos1 = new Pos(); Pos@ pos2; @pos2 = @pos1; pos1.x = 2;
if ( @pos2 == null )
{ }
int@ intVal = new int(); }
};
|
bool 
暗黙の変換 
算術計算の変換 
デリゲート 
|