Every value in Jazz is of some certain type, we will talk about types available by default in Jazz.

Scalar Types

A scalar type represents a single value. Jazz got four primary scalar types: floating-point numbers,booleans,integer nubmers and character types.

Integer types

Jazz got these integer types:

  • int8: signed byte type with range -255..255

  • int16: signed short type with range -32768..32767

  • int32(int): signed int type with range -2147483648..2147483647

  • int64: signed long type with range -9223372036854775808..9223372036854775807

  • uint8: unsigned byte type with range 0..255

  • uint16: unsigned short type with range 0..32767

  • uint32: unsigned int type with range 0..2147483647

  • uint64: unsigned long type with range: 0..9223372036854775807

Floating-point types

  • float32 (float): 32-bits size floating point

  • float64: 64-bits size floating point

  • float80: 80-bits size floating point(padded to 128 bits usually)

Boolean type

A boolean type in Jazz has two possible values: true and false. Booleans are one byte in size. The Boolean type in Jazz is specified using bool.

fun main() {
var x: bool = true;