类型 位宽度
Double 64
Float 32
Long 64
Int 32
Short 16
Byte 8

类型转换

  1. toByte(): Byte
  2. toShort(): Short
  3. toInt(): Int
  4. toLong(): Long
  5. toFloat(): Float
  6. toDouble(): Double
  7. toChar(): Char

位操作符

  1. shl(bits) – 左移位 (Java’s <<)
  2. shr(bits) – 右移位 (Java’s >>)
  3. ushr(bits) – 无符号右移位 (Java’s >>>)
  4. and(bits) – 与
  5. or(bits) – 或
  6. xor(bits) – 异或
  7. inv() – 反向

字符

  1. c: Char = '1';